| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959 |
- <template>
- <div class="task-setting-container">
- <!-- 背景网格装饰 -->
- <div class="grid-bg"></div>
- <!-- 头部区域:军事风格 - 庄重威严 -->
- <div class="header">
- <div class="header-logo flex items-center">
- <i class="el-icon-shield text-red-500 mr-2 text-xl"></i>
- <h1>任务想定编辑</h1>
- </div>
- <div class="header-controls">
- <el-button type="success" icon="el-icon-back" @click="goBack" class="btn军事">
- 返回
- </el-button>
- <el-button type="primary" icon="el-icon-save" @click="saveTask" class="btn军事">
- 保存任务
- </el-button>
- <el-button type="warning" icon="el-icon-refresh" @click="resetTask" class="btn军事">
- 重置
- </el-button>
- </div>
- </div>
- <!-- 主布局容器:大屏分区明确 -->
- <el-container class="h-[calc(100vh-60px)] flex-row overflow-hidden">
- <!-- 左侧栏:任务配置 -->
- <el-aside width="20%" class="min-w-[240px] border-right border-[#0c4a6e] relative">
- <div class="aside-border-decoration"></div>
- <div class="task-panel h-full">
- <div class="task-content">
- <!-- 基本信息:大屏简洁风格 -->
- <div class="section-card mb-6">
- <div class="section-header">
- <h4 class="section-title">
- <i class="el-icon-info"></i>
- 基本信息
- </h4>
- </div>
- <el-form :model="taskForm" label-width="100px" size="small" class="p-4">
- <el-form-item label="任务名称" class="mb-3">
- <el-input v-model="taskForm.name" placeholder="请输入任务名称" :disabled="true" />
- </el-form-item>
- <el-form-item label="任务类别" class="mb-3">
- <el-select v-model="taskForm.category" placeholder="请选择任务类别" :disabled="true">
- <el-option label="保障任务" value="support" />
- <el-option label="实战任务" value="combat" />
- </el-select>
- </el-form-item>
- <el-form-item label="任务类型" class="mb-3">
- <el-select v-model="taskForm.type" placeholder="请选择任务类型" :disabled="true">
- <el-option label="防空作战" value="air-defense" />
- <el-option label="对海作战" value="sea-combat" />
- <el-option label="对地打击" value="ground-strike" />
- <el-option label="电子对抗" value="electronic-warfare" />
- </el-select>
- </el-form-item>
- <el-form-item label="导弹类型" class="mb-3">
- <el-select v-model="taskForm.missileType" placeholder="请选择导弹类型" @change="updateTargetsByMissileType" :disabled="true">
- <el-option label="地空导弹" value="surface-to-air" />
- <el-option label="空地导弹" value="air-to-surface" />
- <el-option label="反舰导弹" value="anti-ship" />
- <el-option label="巡航导弹" value="cruise" />
- </el-select>
- </el-form-item>
- <el-form-item label="导弹数量" class="mb-3">
- <el-input-number v-model="taskForm.missileCount" :min="1" :max="100" size="small" @change="updateTargetsByMissileCount" :disabled="true" />
- </el-form-item>
- <el-form-item label="执行时间" class="mb-3">
- <el-date-picker
- v-model="taskForm.executeTime"
- type="datetime"
- placeholder="选择执行时间"
- format="yyyy-MM-dd HH:mm:ss"
- value-format="yyyy-MM-dd HH:mm:ss"
- :disabled="true"
- />
- </el-form-item>
- <el-form-item label="任务依据">
- <el-input
- v-model="taskForm.description"
- type="textarea"
- :rows="3"
- placeholder="请输入任务依据"
- :disabled="true"
- />
- </el-form-item>
- </el-form>
- </div>
- <!-- 靶标设置 -->
- <div class="section-card mb-6">
- <div class="section-header">
- <h4 class="section-title">
- <i class="el-icon-location"></i>
- 靶标设置
- </h4>
- <el-button type="text" icon="el-icon-plus" @click="addTarget" class="text-green-400" :disabled="!canAddMoreTargets">
- 添加靶标
- </el-button>
- </div>
- <div class="target-list p-4">
- <div class="target-hint text-xs text-yellow-400 mb-2" v-if="taskForm.targets.length < taskForm.missileCount">
- 提示:可添加 {{ taskForm.missileCount - taskForm.targets.length }} 个靶标
- </div>
- <div class="target-hint text-xs text-red-400 mb-2" v-if="taskForm.targets.length > taskForm.missileCount">
- 警告:靶标数量超过导弹数量 {{ taskForm.targets.length - taskForm.missileCount }} 个
- </div>
- <div
- class="target-item p-3 mb-3"
- v-for="target in taskForm.targets"
- :key="target.id"
- >
- <div class="target-header flex justify-between items-center mb-2">
- <span class="target-name font-bold truncate max-w-[150px]">{{ target.name }}</span>
- <div class="target-actions flex">
- <el-button type="text" icon="el-icon-edit" @click="editTarget(target)" class="p-1 text-blue-400" />
- <el-button type="text" icon="el-icon-delete" @click="removeTarget(target)" class="p-1 text-red-400" />
- </div>
- </div>
- <div class="target-info flex justify-between text-sm">
- <span class="target-type">{{ target.type }}</span>
- <span class="target-coord truncate max-w-[120px]">{{ target.coordinates }}</span>
- </div>
- <div class="target-threat mt-2 flex items-center text-xs">
- <span class="mr-2">威胁等级:</span>
- <div class="threat-bars flex gap-1">
- <div
- class="threat-bar"
- v-for="n in 5"
- :key="n"
- :class="{ 'active': n <= target.threatLevel }"
- ></div>
- </div>
- </div>
- <div class="target-equipment mt-2 text-xs text-gray-400">
- <span>负责装备:</span>
- <el-select v-model="target.equipmentId" placeholder="选择装备" size="mini" @change="updateTargetEquipment(target.id, $event)">
- <el-option
- v-for="equip in allEquipment"
- :key="equip.id"
- :label="equip.label"
- :value="equip.id"
- />
- </el-select>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </el-aside>
- <!-- 中间主区域:装备配置(整合设备树和设备策略) -->
- <el-main class="p-0 h-full flex flex-col relative">
- <div class="main-border-decoration"></div>
- <!-- 装备配置内容区 -->
- <div class="equipment-content-box flex-1 overflow-y-auto p-4">
- <!-- 装备配置标题 -->
- <div class="section-card mb-6">
- <div class="section-header">
- <h4 class="section-title">
- <i class="el-icon-cpu mr-2"></i>
- 装备配置
- </h4>
- </div>
- <!-- 装备树和详情的分栏布局 -->
- <div class="equipment-config-container p-4 grid grid-cols-3 gap-4">
- <!-- 左侧:装备树形结构 -->
- <div class="equipment-tree-container col-span-1">
- <div class="section-card h-full">
- <div class="equipment-tree p-3">
- <el-tree
- :data="equipmentTree"
- :props="defaultProps"
- node-key="id"
- @node-click="handleEquipmentClick"
- :expand-on-click-node="false"
- :highlight-current="true"
- >
- <span slot-scope="{ node, data }" class="custom-tree-node">
- <span class="tree-node-content flex items-center">
- <i :class="getEquipmentIcon(data)" class="mr-2"></i>
- <span>{{ node.label }}</span>
- <span v-if="data.indicatorClass" class="ml-2 w-2 h-2 rounded-full" :class="data.indicatorClass"></span>
- </span>
- </span>
- </el-tree>
- </div>
- </div>
- </div>
- <!-- 右侧:装备详情和策略配置 -->
- <div class="equipment-details-container col-span-2">
- <div v-if="selectedEquipment" class="section-card h-full">
- <div class="section-header">
- <h4 class="section-title">
- <i :class="getEquipmentIcon(selectedEquipment)" class="mr-2"></i>
- {{ selectedEquipment.label }} - 配置详情
- </h4>
- </div>
- <div class="equipment-detail p-4">
- <div class="grid grid-cols-2 gap-4 mb-4">
- <div v-for="(item, index) in selectedEquipment.details" :key="index" class="detail-item">
- <div class="detail-label text-sm text-gray-400">{{ item.label }}</div>
- <div class="detail-value font-medium">{{ item.value }}</div>
- </div>
- </div>
- <div class="mt-4 pt-4 border-t border-blue-900/30">
- <h5 class="text-sm font-medium mb-3 text-blue-300">装备策略配置</h5>
- <el-form :model="selectedEquipmentStrategy" label-width="100px" size="small">
- <el-form-item label="工作模式">
- <el-select
- v-model="selectedEquipmentStrategy.mode"
- placeholder="选择工作模式"
- size="small"
- >
- <el-option v-for="option in selectedEquipmentStrategy.options" :key="option.value" :label="option.label" :value="option.value" />
- </el-select>
- </el-form-item>
- <el-form-item label="工作状态">
- <el-select
- v-model="selectedEquipment.status"
- placeholder="选择工作状态"
- size="small"
- @change="updateEquipmentStatus"
- >
- <el-option label="待命" value="standby" />
- <el-option label="就绪" value="ready" />
- <el-option label="维护中" value="maintenance" />
- </el-select>
- </el-form-item>
- <el-form-item label="部署位置">
- <el-select
- v-model="selectedEquipment.position"
- placeholder="选择部署位置"
- size="small"
- @change="updateEquipmentPosition"
- >
- <el-option label="左翼" value="left" />
- <el-option label="右翼" value="right" />
- <el-option label="中央" value="center" />
- <el-option label="前沿" value="front" />
- <el-option label="后方" value="rear" />
- </el-select>
- </el-form-item>
- <el-form-item label="优先级">
- <el-input-number v-model="selectedEquipmentStrategy.params.priority" :min="1" :max="10" size="mini" />
- </el-form-item>
- <el-form-item label="响应时间">
- <el-input-number v-model="selectedEquipmentStrategy.params.responseTime" :min="1" size="mini" />
- </el-form-item>
- <el-form-item label="备注信息">
- <el-input
- v-model="selectedEquipment.notes"
- type="textarea"
- :rows="2"
- placeholder="请输入备注信息"
- @change="updateEquipmentNotes"
- />
- </el-form-item>
- </el-form>
- </div>
- </div>
- </div>
- <div v-else class="section-card h-full flex items-center justify-center p-4 text-gray-400">
- <div class="text-center">
- <i class="el-icon-cpu text-3xl mb-2"></i>
- <p>请从左侧选择一个装备查看详情</p>
- </div>
- </div>
- </div>
- </div>
- </div>
- <!-- 装备数量概览 -->
- <div class="section-card mb-6">
- <div class="section-header">
- <h4 class="section-title">
- <i class="el-icon-dashboard mr-2"></i>
- 装备数量概览
- </h4>
- </div>
- <div class="equipment-status-grid p-4 grid grid-cols-4 gap-3">
- <div class="status-card p-3 border border-blue-500/30 rounded">
- <div class="status-title text-sm text-gray-400 mb-1">总装备数</div>
- <div class="status-value text-2xl font-bold">{{ totalEquipment }}</div>
- </div>
- <div class="status-card p-3 border border-green-500/30 rounded">
- <div class="status-title text-sm text-gray-400 mb-1">测量装备数</div>
- <div class="status-value text-2xl font-bold text-green-400">{{ measurementEquipmentCount }}</div>
- </div>
- <div class="status-card p-3 border border-purple-500/30 rounded">
- <div class="status-title text-sm text-gray-400 mb-1">干扰装备数</div>
- <div class="status-value text-2xl font-bold text-purple-400">{{ jammingEquipmentCount }}</div>
- </div>
- <div class="status-card p-3 border border-red-500/30 rounded">
- <div class="status-title text-sm text-gray-400 mb-1">靶标装备数</div>
- <div class="status-value text-2xl font-bold text-red-400">{{ targetEquipmentCount }}</div>
- </div>
- </div>
- </div>
- <!-- 靶标-装备分配关系 -->
- <div class="section-card">
- <div class="section-header">
- <h4 class="section-title">
- <i class="el-icon-link mr-2"></i>
- 靶标-装备分配关系
- </h4>
- </div>
- <div class="target-equipment-map p-4">
- <el-table
- :data="targetEquipmentMapData"
- border
- size="small"
- :header-cell-style="{background: 'rgba(30, 58, 138, 0.3)', color: '#bae6fd', borderColor: 'rgba(14, 165, 233, 0.2)'}"
- :row-style="{background: 'rgba(15, 23, 42, 0.5)', color: '#e0f2fe', borderColor: 'rgba(14, 165, 233, 0.1)'}"
- >
- <el-table-column prop="targetName" label="靶标名称"></el-table-column>
- <el-table-column prop="targetType" label="靶标类型"></el-table-column>
- <el-table-column prop="threatLevel" label="威胁等级">
- <template slot-scope="scope">
- <div class="threat-bars flex gap-1 justify-center">
- {{scope.row.threatLevel}}
- <div
- class="threat-bar"
- v-for="n in 5"
- :key="n"
- :class="{ 'active': n <= scope.row.threatLevel }"
- ></div>
- </div>
- </template>
- </el-table-column>
- <el-table-column prop="equipmentName" label="负责装备" width="180"></el-table-column>
- <el-table-column prop="equipmentStatus" label="装备状态" width="100">
- <template slot-scope="scope">
- <span :class="statusLabelClass(scope.row.equipmentStatus)">{{ equipmentStatusText(scope.row.equipmentStatus) }}</span>
- </template>
- </el-table-column>
- </el-table>
- </div>
- </div>
- </div>
- </el-main>
- <!-- 右侧栏:任务预览(优化布局) -->
- <el-aside width="20%" class="min-w-[240px] border-left border-[#0c4a6e] relative">
- <div class="aside-border-decoration"></div>
- <div class="preview-panel h-full">
- <div class="preview-content p-4">
- <!-- 任务类型信息(放在最上面) -->
- <div class="preview-section mb-4 p-3">
- <div class="task-type-title text-center text-lg font-bold text-blue-300 mb-1">{{ taskTypeName }}</div>
- <div class="task-category text-center text-sm text-gray-400">{{ taskCategoryName }}</div>
- <div class="task-missile text-center text-xs mt-2 text-gray-400">
- 导弹类型: {{ missileTypeName || '未选择' }}
- </div>
- </div>
- <!-- 任务概览:紧凑布局 -->
- <div class="preview-section mb-4">
- <h4 class="p-2 font-medium border-b m-0 text-sm">任务概览</h4>
- <div class="overview-stats p-3">
- <div class="stat-row-compact flex justify-between items-center py-1 border-b border-blue-900/10">
- <span class="stat-label-compact text-xs">靶标数量</span>
- <span class="stat-value-compact font-bold">{{ taskForm.targets.length }}</span>
- </div>
- <div class="stat-row-compact flex justify-between items-center py-1 border-b border-blue-900/10">
- <span class="stat-label-compact text-xs">导弹数量</span>
- <span class="stat-value-compact font-bold">{{ taskForm.missileCount || 0 }}</span>
- </div>
- <div class="stat-row-compact flex justify-between items-center py-1 border-b border-blue-900/10">
- <span class="stat-label-compact text-xs">装备总数</span>
- <span class="stat-value-compact font-bold">{{ totalEquipment }}</span>
- </div>
- <div class="stat-row-compact flex justify-between items-center py-1 border-b border-blue-900/10">
- <span class="stat-label-compact text-xs">就绪装备</span>
- <span class="stat-value-compact font-bold text-green-400">{{ readyEquipmentCount }}</span>
- </div>
- <div class="stat-row-compact flex justify-between items-center py-1">
- <span class="stat-label-compact text-xs">执行时间</span>
- <span class="stat-value-compact font-bold text-xs truncate">{{ taskForm.executeTime || '未指定' }}</span>
- </div>
- <div class="stat-row-compact flex justify-between items-center py-1">
- <span class="stat-label-compact text-xs">倒计时</span>
- <span class="stat-value-compact font-bold text-xs text-yellow-400">{{ formattedCountdown }}</span>
- </div>
- </div>
- </div>
- <!-- 执行时间轴:紧凑布局 -->
- <div class="preview-section">
- <h4 class="p-2 font-medium border-b m-0 text-sm">执行时间轴</h4>
- <div class="timeline-container p-3 relative">
- <div class="timeline-line absolute top-0 bottom-0 left-3 w-0.5"></div>
- <div
- class="timeline-item-compact relative mb-3 pl-8"
- v-for="event in events"
- :key="event.id"
- >
- <div class="timeline-dot absolute left-0 top-1 w-5 h-5 rounded-full flex items-center justify-center z-10" :class="dotClassMap[event.dotClass]">
- <div class="w-1.5 h-1.5 rounded-full bg-white"></div>
- </div>
- <div class="timeline-content-compact">
- <div class="flex justify-between items-start mb-0">
- <div class="timeline-time text-xs font-bold">{{ event.time }}</div>
- <!-- <div class="timeline-status text-xs px-1.5 py-0 rounded" :class="statusClassMap[event.dotClass]">{{ event.status }}</div>-->
- <div class="timeline-title text-xs font-bold">{{ event.title }}</div>
- </div>
- <!-- <div class="timeline-title text-xs font-bold">{{ event.title }}</div>-->
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </el-aside>
- </el-container>
- <!-- 添加靶标对话框 -->
- <el-dialog
- title="添加靶标"
- :visible.sync="showTargetDialog"
- width="30%"
- custom-class="target-dialog"
- >
- <el-form :model="targetForm" label-width="100px">
- <el-form-item label="靶标名称">
- <el-input v-model="targetForm.name" placeholder="请输入靶标名称"></el-input>
- </el-form-item>
- <el-form-item label="靶标类型">
- <el-select v-model="targetForm.type" placeholder="请选择靶标类型">
- <el-option label="空中靶标" value="空中靶标" :disabled="!isAirTargetAllowed"></el-option>
- <el-option label="海上靶标" value="海上靶标" :disabled="!isSeaTargetAllowed"></el-option>
- <el-option label="地面靶标" value="地面靶标" :disabled="!isGroundTargetAllowed"></el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="坐标位置">
- <el-input v-model="targetForm.coordinates" placeholder="格式:东经XX°XX′,北纬XX°XX′"></el-input>
- </el-form-item>
- <el-form-item label="威胁等级">
- <el-slider v-model="targetForm.threatLevel" :min="1" :max="5" show-input />
- </el-form-item>
- <el-form-item label="负责装备">
- <el-select v-model="targetForm.equipmentId" placeholder="选择负责装备">
- <el-option
- v-for="equip in allEquipment"
- :key="equip.id"
- :label="equip.label"
- :value="equip.id"
- />
- </el-select>
- </el-form-item>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button @click="showTargetDialog = false" class="btn军事">取消</el-button>
- <el-button type="primary" @click="confirmAddTarget" class="btn军事">确定</el-button>
- </div>
- </el-dialog>
- </div>
- </template>
- <script>
- export default {
- components: {},
- data() {
- return {
- // 时间显示
- 天文时间: '',
- 绝对时间: '',
- // 任务表单数据 - 设置默认值
- taskForm: {
- name: '红旗-9B防空导弹拦截试验',
- category: 'combat', // 任务类别:support-保障任务,combat-实战任务
- type: 'air-defense',
- missileType: 'surface-to-air', // 导弹类型
- missileCount: 6, // 导弹数量
- executeTime: '2025-10-15 14:30:00',
- description: '本次试验旨在验证红旗-9B防空导弹系统对多批次、多类型空中靶标的拦截能力,测试在强电子干扰环境下的作战效能。',
- targets: [
- {
- id: 1,
- name: '高空侦察机',
- type: '空中靶标',
- coordinates: '东经121°25′,北纬30°15′',
- threatLevel: 5,
- equipmentId: 'A1'
- },
- {
- id: 2,
- name: '巡航导弹模拟靶',
- type: '空中靶标',
- coordinates: '东经121°30′,北纬30°20′',
- threatLevel: 4,
- equipmentId: 'A1'
- },
- {
- id: 3,
- name: '隐身战机模拟靶',
- type: '空中靶标',
- coordinates: '东经121°20′,北纬30°25′',
- threatLevel: 5,
- equipmentId: 'B2'
- }
- ]
- },
- // 装备树形结构数据
- equipmentTree: [
- {
- id: 'category1',
- label: '测量装备',
- children: [
- {
- id: 'A1',
- label: '高空观测装置A1',
- side: '',
- indicatorClass: 'bg-blue-500',
- status: 'ready',
- position: 'front',
- notes: '',
- details: [
- { label: '状态', value: '运行中' },
- { label: '覆盖范围', value: '3500米' },
- { label: '高度', value: '5000米' },
- { label: '观测精度', value: '92%' },
- { label: '功率', value: '100%' },
- { label: '电量', value: '86%' },
- { label: '发现目标', value: '3个' },
- { label: '数据链路', value: '稳定' }
- ]
- },
- {
- id: 'B2',
- label: '地面观测装置B2',
- side: '',
- indicatorClass: 'bg-blue-500',
- status: 'ready',
- position: 'center',
- notes: '',
- details: [
- { label: '状态', value: '运行中' },
- { label: '覆盖范围', value: '1200米' },
- { label: '高度', value: '100米' },
- { label: '观测精度', value: '88%' },
- { label: '功率', value: '90%' },
- { label: '电量', value: '92%' },
- { label: '发现目标', value: '2个' },
- { label: '数据链路', value: '稳定' }
- ]
- },
- {
- id: 'C3',
- label: '移动观测装置C3',
- side: '',
- indicatorClass: 'bg-blue-500',
- status: 'standby',
- position: 'rear',
- notes: '',
- details: [
- { label: '状态', value: '待命' },
- { label: '覆盖范围', value: '800米' },
- { label: '速度', value: '40km/h' },
- { label: '观测精度', value: '85%' },
- { label: '功率', value: '70%' },
- { label: '电量', value: '95%' },
- { label: '发现目标', value: '0个' },
- { label: '数据链路', value: '稳定' }
- ]
- }
- ]
- },
- {
- id: 'category2',
- label: '干扰装备',
- children: [
- {
- id: 'D1',
- label: '雷达干扰器D1',
- side: '',
- indicatorClass: 'bg-purple-500',
- status: 'standby',
- position: 'left',
- notes: '',
- details: [
- { label: '状态', value: '待命' },
- { label: '功率', value: '60%' },
- { label: '高度', value: '50米' },
- { label: '覆盖范围', value: '2000米' },
- { label: '电量', value: '95%' },
- { label: '干扰类型', value: '雷达波' },
- { label: '有效距离', value: '5km' },
- { label: '数据链路', value: '稳定' }
- ]
- },
- {
- id: 'E2',
- label: '光电干扰器E2',
- side: '',
- indicatorClass: 'bg-purple-500',
- status: 'ready',
- position: 'right',
- notes: '',
- details: [
- { label: '状态', value: '运行中' },
- { label: '功率', value: '80%' },
- { label: '干扰波段', value: '可见光-红外' },
- { label: '覆盖范围', value: '1500米' },
- { label: '电量', value: '88%' },
- { label: '干扰强度', value: '强' },
- { label: '数据链路', value: '稳定' }
- ]
- }
- ]
- },
- {
- id: 'category3',
- label: '靶标装备',
- children: [
- {
- id: 'redA',
- label: '空中靶标A集群',
- side: '',
- indicatorClass: 'bg-red-500',
- status: 'ready',
- position: 'front',
- notes: '',
- details: [
- { label: '状态', value: '就绪' },
- { label: '数量', value: '5' },
- { label: '速度', value: '350m/s' },
- { label: '高度', value: '2000米' },
- { label: '机动能力', value: '高' },
- { label: '雷达反射面积', value: '0.1-5㎡' },
- { label: '数据链路', value: '可控' }
- ]
- },
- {
- id: 'redB',
- label: '海上靶标B',
- side: '',
- indicatorClass: 'bg-red-500',
- status: 'standby',
- position: 'front',
- notes: '',
- details: [
- { label: '状态', value: '待命' },
- { label: '排水量', value: '500吨' },
- { label: '速度', value: '30节' },
- { label: '雷达反射面积', value: '500㎡' },
- { label: '机动能力', value: '中' },
- { label: '数据链路', value: '可控' }
- ]
- }
- ]
- }
- ],
- defaultProps: {
- children: 'children',
- label: 'label'
- },
- // 选中装备的策略配置
- selectedEquipmentStrategy: {
- mode: '',
- options: [],
- params: {
- priority: 5,
- responseTime: 30
- }
- },
- // 时间轴事件数据
- events: [
- {
- id: 1,
- title: '靶标装备就位',
- time: 'T+00:00:00',
- description: '所有靶标装备到达指定位置',
- status: '全部就位',
- dotClass: 'warning',
- position: 50
- },
- {
- id: 2,
- title: '导弹准备发射',
- time: 'T+00:01:45',
- description: '导弹系统进入发射准备阶段',
- status: '准备中...',
- dotClass: 'warning',
- position: 70
- },
- {
- id: 3,
- title: '干扰装备启动',
- time: 'T-00:02:30',
- description: '干扰装备D1和E2开始启动',
- status: '功率: 60%',
- dotClass: 'info',
- position: 30
- },
- {
- id: 4,
- title: '试验开始',
- time: 'T+00:03:20',
- description: '导弹发射,测量系统开始记录数据',
- status: '进行中',
- dotClass: 'danger',
- position: 90
- },
- {
- id: 5,
- title: '观测装置部署完成',
- time: 'T-00:05:00',
- description: '完成高空观测装置A1、地面观测装置B2部署',
- status: '覆盖率: 92%',
- dotClass: 'info',
- position: 10
- },
- ],
- // 其他状态
- showTargetDialog: false,
- targetForm: {
- name: '',
- type: '',
- coordinates: '',
- threatLevel: 3,
- equipmentId: ''
- },
- selectedEquipment: null,
- // 时间轴点颜色映射
- dotClassMap: {
- info: 'bg-blue-500', // 信息蓝
- warning: 'bg-yellow-500', // 警告黄
- danger: 'bg-red-500' // 危险红
- },
- // 状态标签样式映射
- statusClassMap: {
- info: 'bg-blue-900/50 text-blue-300',
- warning: 'bg-yellow-900/50 text-yellow-300',
- danger: 'bg-red-900/50 text-red-300'
- }
- }
- },
- computed: {
- measurementEquipmentCount() {
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.id === 'category1' && category.children) {
- count += category.children.length;
- }
- });
- return count;
- },
- jammingEquipmentCount() {
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.id === 'category2' && category.children) {
- count += category.children.length;
- }
- });
- return count;
- },
- targetEquipmentCount() {
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.id === 'category3' && category.children) {
- count += category.children.length;
- }
- });
- return count;
- },
- totalEquipment() {
- // 计算所有装备的总数
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.children && category.children.length) {
- count += category.children.length;
- }
- });
- return count;
- },
- readyEquipmentCount() {
- // 计算就绪状态的装备数量
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.children && category.children.length) {
- category.children.forEach(equip => {
- if (equip.status === 'ready') count++;
- });
- }
- });
- return count;
- },
- standbyEquipmentCount() {
- // 计算待命状态的装备数量
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.children && category.children.length) {
- category.children.forEach(equip => {
- if (equip.status === 'standby') count++;
- });
- }
- });
- return count;
- },
- maintenanceEquipmentCount() {
- // 计算维护中状态的装备数量
- let count = 0;
- this.equipmentTree.forEach(category => {
- if (category.children && category.children.length) {
- category.children.forEach(equip => {
- if (equip.status === 'maintenance') count++;
- });
- }
- });
- return count;
- },
- allEquipment() {
- // 提取所有装备列表
- let equipment = [];
- this.equipmentTree.forEach(category => {
- if (category.children && category.children.length) {
- equipment = [...equipment, ...category.children];
- }
- });
- return equipment;
- },
- /*sortedEvents() {
- // 按时间排序事件,从T0开始递增
- return [...this.events].sort((a, b) => {
- // 解析时间格式为秒数以便比较
- const getSeconds = (timeStr) => {
- const sign = timeStr.startsWith('T+') ? 1 : -1;
- const timePart = timeStr.substring(2);
- const [hours, minutes, seconds] = timePart.split(':').map(Number);
- return sign * (hours * 3600 + minutes * 60 + seconds);
- };
- return getSeconds(a.time) - getSeconds(b.time);
- });
- },*/
- taskTypeName() {
- const typeMap = {
- 'air-defense': '防空作战',
- 'sea-combat': '对海作战',
- 'ground-strike': '对地打击',
- 'electronic-warfare': '电子对抗'
- };
- return typeMap[this.taskForm.type] || '未设置';
- },
- taskCategoryName() {
- const categoryMap = {
- 'support': '保障任务',
- 'combat': '实战任务'
- };
- return categoryMap[this.taskForm.category] || '未设置';
- },
- missileTypeName() {
- const missileTypeMap = {
- 'surface-to-air': '地空导弹',
- 'air-to-surface': '空地导弹',
- 'anti-ship': '反舰导弹',
- 'cruise': '巡航导弹'
- };
- return missileTypeMap[this.taskForm.missileType] || '';
- },
- canAddMoreTargets() {
- // 控制是否可以添加更多靶标
- return this.taskForm.missileCount > 0 && this.taskForm.targets.length < this.taskForm.missileCount * 2;
- },
- // 根据导弹类型判断允许的靶标类型
- isAirTargetAllowed() {
- return ['surface-to-air', 'air-to-surface', 'cruise'].includes(this.taskForm.missileType);
- },
- isSeaTargetAllowed() {
- return ['anti-ship', 'cruise'].includes(this.taskForm.missileType);
- },
- isGroundTargetAllowed() {
- return ['air-to-surface', 'cruise'].includes(this.taskForm.missileType);
- },
- formattedCountdown() {
- // 计算倒计时
- if (!this.taskForm.executeTime) return '未设置执行时间';
- const executeTime = new Date(this.taskForm.executeTime).getTime();
- const now = new Date().getTime();
- const diff = executeTime - now;
- if (diff < 0) return '已过期';
- const days = Math.floor(diff / (1000 * 60 * 60 * 24));
- const hours = Math.floor((diff % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
- const minutes = Math.floor((diff % (1000 * 60 * 60)) / (1000 * 60));
- return `${days}天${hours}时${minutes}分后执行`;
- },
- targetEquipmentMapData() {
- // 构建靶标-装备关系数据
- return this.taskForm.targets.map(target => {
- const equipment = this.allEquipment.find(equip => equip.id === target.equipmentId);
- return {
- targetName: target.name,
- targetType: target.type,
- threatLevel: target.threatLevel,
- equipmentName: equipment ? equipment.label : '未分配',
- equipmentStatus: equipment ? equipment.status : ''
- };
- });
- }
- },
- methods: {
- startShow() {
- this.$router.push('/Deduction/stratDeduction')
- },
- saveTask() {
- // 验证靶标设置不能为空
- if (this.taskForm.targets.length === 0) {
- this.$message.error('靶标设置不能为空,请添加至少一个靶标');
- return;
- }
- this.$message.success('任务保存成功')
- },
- goBack(){
- // 返回上一页逻辑
- this.$confirm('确定要退出吗?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- this.$router.go(-1)
- }).catch(() => {
- // 取消重置
- });
- },
- startSimulation() {
- this.$message.info('开始任务推演...')
- },
- resetTask() {
- this.$confirm('确定要重置任务配置吗?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- // 重置表单逻辑
- this.$message.success('任务配置已重置');
- }).catch(() => {
- // 取消重置
- });
- },
- addTarget() {
- this.targetForm = {
- name: '',
- type: '',
- coordinates: '',
- threatLevel: 3,
- equipmentId: ''
- };
- this.showTargetDialog = true;
- },
- confirmAddTarget() {
- if (!this.targetForm.name || !this.targetForm.type || !this.targetForm.coordinates) {
- this.$message.warning('请填写完整靶标信息');
- return;
- }
- this.taskForm.targets.push({
- id: Date.now(),
- ...this.targetForm
- });
- this.showTargetDialog = false;
- this.$message.success('靶标添加成功');
- },
- editTarget(target) {
- this.targetForm = { ...target };
- this.showTargetDialog = true;
- },
- removeTarget(target) {
- this.$confirm(`确定要删除靶标"${target.name}"吗?`, '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- this.taskForm.targets = this.taskForm.targets.filter(t => t.id !== target.id);
- this.$message.success('靶标已删除');
- }).catch(() => {
- // 取消删除
- });
- },
- // 处理装备点击事件
- handleEquipmentClick(data) {
- // 只处理叶子节点(具体装备)
- if (!data.children || data.children.length === 0) {
- this.selectedEquipment = { ...data };
- // 设置该装备对应的策略选项
- this.setEquipmentStrategyOptions(data);
- }
- },
- // 根据装备类型设置策略选项
- setEquipmentStrategyOptions(equipment) {
- // 根据不同类型的装备设置不同的策略选项
- if (equipment.id.startsWith('A') || equipment.id.startsWith('B') || equipment.id.startsWith('C')) {
- // 测量装备
- this.selectedEquipmentStrategy = {
- mode: 'track',
- options: [
- { label: '持续跟踪', value: 'track' },
- { label: '重点跟踪', value: 'focus' },
- { label: '扫描跟踪', value: 'scan' }
- ],
- params: {
- priority: 3,
- responseTime: 10
- }
- };
- } else if (equipment.id.startsWith('D') || equipment.id.startsWith('E')) {
- // 干扰装备
- this.selectedEquipmentStrategy = {
- mode: 'auto',
- options: [
- { label: '自动干扰模式', value: 'auto' },
- { label: '手动干扰模式', value: 'manual' },
- { label: '前置干扰模式', value: 'preemptive' }
- ],
- params: {
- priority: 5,
- responseTime: 30
- }
- };
- } else if (equipment.id.startsWith('red')) {
- // 靶标装备
- this.selectedEquipmentStrategy = {
- mode: 'evade',
- options: [
- { label: '规避模式', value: 'evade' },
- { label: '突防模式', value: 'penetrate' },
- { label: '佯动模式', value: 'feint' }
- ],
- params: {
- priority: 4,
- responseTime: 5
- }
- };
- }
- },
- // 更新装备状态
- updateEquipmentStatus() {
- this.updateEquipmentData();
- },
- // 更新装备位置
- updateEquipmentPosition() {
- this.updateEquipmentData();
- },
- // 更新装备备注
- updateEquipmentNotes() {
- this.updateEquipmentData();
- },
- // 更新树形结构中的装备数据
- updateEquipmentData() {
- if (!this.selectedEquipment) return;
- const updateNode = (nodes) => {
- for (let i = 0; i < nodes.length; i++) {
- if (nodes[i].id === this.selectedEquipment.id) {
- nodes[i] = { ...this.selectedEquipment };
- return true;
- }
- if (nodes[i].children && nodes[i].children.length) {
- if (updateNode(nodes[i].children)) {
- return true;
- }
- }
- }
- return false;
- };
- updateNode(this.equipmentTree);
- },
- // 更新靶标关联的装备
- updateTargetEquipment(targetId, equipmentId) {
- const target = this.taskForm.targets.find(t => t.id === targetId);
- if (target) {
- target.equipmentId = equipmentId;
- }
- },
- // 根据导弹类型更新靶标设置
- updateTargetsByMissileType() {
- // 根据选择的导弹类型过滤不兼容的靶标
- if (!this.taskForm.missileType) return;
- const compatibleTypes = [];
- if (this.isAirTargetAllowed) compatibleTypes.push('空中靶标');
- if (this.isSeaTargetAllowed) compatibleTypes.push('海上靶标');
- if (this.isGroundTargetAllowed) compatibleTypes.push('地面靶标');
- // 过滤不兼容的靶标
- this.taskForm.targets = this.taskForm.targets.filter(target =>
- compatibleTypes.includes(target.type)
- );
- // 如果没有靶标,自动创建一个兼容的靶标
- if (this.taskForm.targets.length === 0) {
- this.taskForm.targets.push({
- id: Date.now(),
- name: `靶标${compatibleTypes[0]}`,
- type: compatibleTypes[0],
- coordinates: '东经120°00′,北纬30°00′',
- threatLevel: 3,
- equipmentId: ''
- });
- }
- },
- // 根据导弹数量更新靶标设置
- updateTargetsByMissileCount() {
- // 如果靶标数量超过导弹数量的2倍,删除多余的靶标
- const maxTargets = this.taskForm.missileCount * 2;
- if (this.taskForm.targets.length > maxTargets) {
- this.taskForm.targets = this.taskForm.targets.slice(0, maxTargets);
- this.$message.info(`靶标数量已调整为${maxTargets}个(不超过导弹数量的2倍)`);
- }
- },
- // 获取装备图标
- getEquipmentIcon(data) {
- // 判断是否为类别节点
- if (data.children && data.children.length > 0) {
- return 'el-icon-folder-opened';
- }
- // 根据装备类型返回不同图标
- if (data.id.startsWith('A') || data.id.startsWith('B') || data.id.startsWith('C')) {
- return 'el-icon-eye';
- } else if (data.id.startsWith('D') || data.id.startsWith('E')) {
- return 'el-icon-wifi';
- } else if (data.id.startsWith('red')) {
- return 'el-icon-target';
- }
- return 'el-icon-cpu';
- },
- // 装备状态文本转换
- equipmentStatusText(status) {
- const statusMap = {
- 'ready': '就绪',
- 'standby': '待命',
- 'maintenance': '维护中'
- };
- return statusMap[status] || status;
- },
- // 装备状态标签样式
- statusLabelClass(status) {
- const classMap = {
- 'ready': 'text-green-400 bg-green-900/30 px-1.5 py-0 rounded text-xs',
- 'standby': 'text-yellow-400 bg-yellow-900/30 px-1.5 py-0 rounded text-xs',
- 'maintenance': 'text-red-400 bg-red-900/30 px-1.5 py-0 rounded text-xs'
- };
- return classMap[status] || '';
- },
- // 更新时间显示
- updateTime() {
- const now = new Date();
- this.天文时间 = now.toLocaleString('zh-CN', {
- year: 'numeric',
- month: '2-digit',
- day: '2-digit',
- hour: '2-digit',
- minute: '2-digit',
- second: '2-digit',
- hour12: false
- }).replace(/\//g, '-');
- // 模拟绝对时间
- const epoch = new Date('2000-01-01T00:00:00Z');
- const diff = Math.floor((now - epoch) / 1000);
- this.绝对时间 = `J${diff}`;
- }
- },
- watch: {
- // 监听导弹类型变化,更新靶标设置
- 'taskForm.missileType': function() {
- this.updateTargetsByMissileType();
- }
- },
- mounted() {
- // 初始化时间
- this.updateTime();
- // 每秒更新时间
- setInterval(this.updateTime, 1000);
- }
- }
- </script>
- <style lang="scss" scoped>
- /* 军事风格大屏基础样式 - 深色背景,高对比度 */
- .task-setting-container {
- display: flex;
- flex-direction: column;
- height: 100vh;
- background-color: #050c1a; /* 深色军事背景 */
- color: #e0f2fe; /* 主文本色 - 浅蓝色 */
- font-family: "Microsoft YaHei", Arial, sans-serif;
- position: relative;
- overflow: hidden;
- }
- /* 军事网格背景 */
- .grid-bg {
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- background-size: 40px 40px;
- background-image:
- linear-gradient(to right, rgba(14, 55, 107, 0.1) 1px, transparent 1px),
- linear-gradient(to bottom, rgba(14, 55, 107, 0.1) 1px, transparent 1px);
- pointer-events: none;
- z-index: 0;
- }
- /* 头部样式:军事风格 - 庄重威严 */
- .header {
- flex: 0 0 60px;
- background-color: #0f172a; /* 头部深色背景 */
- background-image: linear-gradient(to right, #0f172a, #1e3a8a);
- display: flex;
- align-items: center;
- padding: 0 20px;
- justify-content: space-between;
- border-bottom: 1px solid #0ea5e9;
- box-shadow: 0 2px 10px rgba(14, 165, 233, 0.2);
- position: relative;
- z-index: 10;
- .header-logo {
- display: flex;
- align-items: center;
- h1 {
- font-size: 1.5rem;
- color: #bae6fd;
- margin: 0;
- white-space: nowrap;
- text-shadow: 0 0 5px rgba(14, 165, 233, 0.5);
- }
- }
- .header-time {
- display: flex;
- gap: 20px;
- color: #93c5fd;
- font-size: 14px;
- .time-item {
- padding: 5px 10px;
- background-color: rgba(15, 23, 42, 0.7);
- border: 1px solid rgba(14, 165, 233, 0.3);
- border-radius: 3px;
- }
- }
- .header-controls {
- display: flex;
- gap: 15px;
- }
- }
- /* 军事风格按钮 */
- .btn军事 {
- position: relative;
- overflow: hidden;
- transition: all 0.3s ease;
- border: 1px solid rgba(14, 165, 233, 0.5) !important;
- box-shadow: 0 0 5px rgba(14, 165, 233, 0.3);
- &:after {
- content: '';
- position: absolute;
- top: 0;
- left: -100%;
- width: 100%;
- height: 100%;
- background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
- transition: all 0.5s ease;
- }
- &:hover:after {
- left: 100%;
- }
- }
- /* 侧边栏装饰线 */
- .aside-border-decoration {
- position: absolute;
- top: 0;
- right: 0;
- width: 3px;
- height: 100%;
- background: linear-gradient(to bottom,
- rgba(14, 165, 233, 0) 0%,
- rgba(14, 165, 233, 0.5) 50%,
- rgba(14, 165, 233, 0) 100%);
- z-index: 1;
- }
- /* 主区域装饰线 */
- .main-border-decoration {
- position: absolute;
- top: 0;
- left: 0;
- width: 3px;
- height: 100%;
- background: linear-gradient(to bottom,
- rgba(14, 165, 233, 0) 0%,
- rgba(14, 165, 233, 0.5) 50%,
- rgba(14, 165, 233, 0) 100%);
- z-index: 1;
- }
- /* 左侧任务面板:军事风格分区明确 */
- .task-panel {
- width: 100%;
- background-color: rgba(15, 23, 42, 0.8);
- backdrop-filter: blur(5px);
- display: flex;
- flex-direction: column;
- min-width: 0;
- overflow: hidden;
- border-right: 1px solid rgba(14, 165, 233, 0.2);
- .panel-header {
- padding: 12px 15px;
- border-bottom: 1px solid rgba(14, 165, 233, 0.3);
- flex-shrink: 0;
- background-color: rgba(30, 58, 138, 0.6);
- background-image: linear-gradient(to right, rgba(30, 58, 138, 0.8), rgba(15, 23, 42, 0.8));
- h3 {
- color: #bae6fd;
- font-size: 1rem;
- margin: 0;
- font-weight: 500;
- display: flex;
- align-items: center;
- }
- }
- .task-content {
- flex: 1;
- overflow-y: auto;
- padding: 15px;
- min-height: 0;
- &::-webkit-scrollbar {
- width: 6px;
- height: 6px;
- }
- &::-webkit-scrollbar-track {
- background: rgba(15, 23, 42, 0.5);
- }
- &::-webkit-scrollbar-thumb {
- background-color: rgba(59, 130, 246, 0.5);
- border-radius: 3px;
- }
- }
- }
- /* 中间装备配置区域 */
- .equipment-content-box {
- background-color: rgba(5, 12, 26, 0.9);
- min-height: 0;
- &::-webkit-scrollbar {
- width: 6px;
- height: 6px;
- }
- &::-webkit-scrollbar-track {
- background: rgba(15, 23, 42, 0.5);
- }
- &::-webkit-scrollbar-thumb {
- background-color: rgba(59, 130, 246, 0.5);
- border-radius: 3px;
- }
- }
- .equipment-config-container {
- height: calc(100% - 40px);
- }
- .equipment-tree-container {
- height: 100%;
- }
- .equipment-details-container {
- height: 100%;
- }
- .equipment-status-grid {
- display: grid;
- grid-template-columns: repeat(4, 1fr);
- gap: 10px;
- }
- .status-card {
- background-color: rgba(15, 23, 42, 0.6);
- border-radius: 3px;
- transition: all 0.2s;
- &:hover {
- transform: translateY(-2px);
- box-shadow: 0 3px 10px rgba(14, 165, 233, 0.1);
- }
- .status-title {
- color: #94a3b8;
- }
- .status-value {
- color: #60a5fa;
- text-shadow: 0 0 3px rgba(59, 130, 246, 0.2);
- }
- }
- /* 树形结构样式 */
- .equipment-tree {
- max-height: calc(100% - 20px);
- overflow-y: auto;
- &::-webkit-scrollbar {
- width: 6px;
- height: 6px;
- }
- &::-webkit-scrollbar-track {
- background: rgba(15, 23, 42, 0.5);
- }
- &::-webkit-scrollbar-thumb {
- background-color: rgba(59, 130, 246, 0.5);
- border-radius: 3px;
- }
- }
- .custom-tree-node {
- width: 100%;
- display: inline-block;
- }
- .tree-node-content {
- width: 100%;
- padding: 2px 0;
- color: #e0f2fe;
- &:hover {
- color: #60a5fa;
- }
- }
- /* 右侧预览面板:军事风格数据突出 */
- .preview-panel {
- width: 100%;
- background-color: rgba(15, 23, 42, 0.8);
- backdrop-filter: blur(5px);
- display: flex;
- flex-direction: column;
- min-width: 0;
- overflow: hidden;
- border-left: 1px solid rgba(14, 165, 233, 0.2);
- .panel-header {
- padding: 12px 15px;
- border-bottom: 1px solid rgba(14, 165, 233, 0.3);
- flex-shrink: 0;
- background-color: rgba(30, 58, 138, 0.6);
- background-image: linear-gradient(to right, rgba(30, 58, 138, 0.8), rgba(15, 23, 42, 0.8));
- }
- .preview-content {
- flex: 1;
- overflow-y: auto;
- min-height: 0;
- &::-webkit-scrollbar {
- width: 6px;
- height: 6px;
- }
- &::-webkit-scrollbar-track {
- background: rgba(15, 23, 42, 0.5);
- }
- &::-webkit-scrollbar-thumb {
- background-color: rgba(59, 130, 246, 0.5);
- border-radius: 3px;
- }
- }
- }
- /* 通用模块样式:军事风格简洁 */
- .section-card {
- background-color: rgba(15, 23, 42, 0.7);
- border-radius: 4px;
- overflow: hidden;
- border: 1px solid rgba(14, 165, 233, 0.3);
- box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
- transition: all 0.3s ease;
- &:hover {
- box-shadow: 0 3px 15px rgba(14, 165, 233, 0.2);
- border-color: rgba(14, 165, 233, 0.5);
- }
- }
- .section-header {
- background-color: rgba(30, 58, 138, 0.5);
- padding: 8px 15px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- border-bottom: 1px solid rgba(14, 165, 233, 0.2);
- .section-title {
- color: #bae6fd;
- font-size: 14px;
- margin: 0;
- font-weight: 500;
- display: flex;
- align-items: center;
- }
- }
- /* 表单样式:军事风格简洁易读 */
- .el-input__inner,
- .el-textarea__inner,
- .el-select .el-input__inner {
- background-color: rgba(15, 23, 42, 0.8);
- border: 1px solid rgba(14, 165, 233, 0.3);
- color: #e0f2fe;
- width: 100%;
- border-radius: 3px;
- height: 32px;
- font-size: 14px;
- &:focus {
- border-color: #3b82f6;
- box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
- }
- &::placeholder {
- color: #64748b;
- }
- &:disabled {
- background-color: rgba(15, 23, 42, 0.5);
- color: #94a3b8;
- cursor: not-allowed;
- }
- }
- .el-textarea__inner {
- min-height: 80px !important;
- height: auto;
- resize: vertical;
- }
- /* 下拉框样式:军事风格简洁 */
- ::v-deep .el-select-dropdown {
- background-color: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(14, 165, 233, 0.3);
- border-radius: 3px;
- box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
- .el-select-dropdown__item {
- color: #e0f2fe;
- padding: 8px 16px;
- font-size: 14px;
- &:hover {
- background-color: rgba(30, 58, 138, 0.5);
- }
- &.selected {
- background-color: rgba(59, 130, 246, 0.5);
- color: white;
- }
- }
- }
- /* 输入框数字控件样式:军事风格简洁 */
- ::v-deep .el-input-number {
- .el-input-number__decrease,
- .el-input-number__increase {
- background-color: rgba(30, 58, 138, 0.5);
- border-color: rgba(14, 165, 233, 0.3);
- color: #e0f2fe;
- width: 30px;
- height: 30px;
- line-height: 30px;
- &:hover {
- background-color: rgba(30, 58, 138, 0.8);
- color: white;
- }
- &:disabled {
- background-color: rgba(15, 23, 42, 0.5);
- color: #94a3b8;
- cursor: not-allowed;
- }
- }
- }
- /* 靶标项样式:军事风格清晰 */
- .target-item {
- background-color: rgba(15, 23, 42, 0.6);
- border: 1px solid rgba(14, 165, 233, 0.2);
- border-radius: 3px;
- transition: all 0.2s;
- &:hover {
- border-color: rgba(14, 165, 233, 0.5);
- background-color: rgba(15, 23, 42, 0.8);
- }
- .target-name {
- color: #bae6fd;
- }
- .target-type {
- color: #60a5fa;
- }
- .target-coord {
- color: #94a3b8;
- }
- .target-threat {
- color: #94a3b8;
- .threat-bars {
- height: 6px;
- }
- .threat-bar {
- width: 6px;
- height: 100%;
- background-color: rgba(100, 116, 139, 0.3);
- border-radius: 1px;
- &.active {
- background-color: #f97316;
- }
- }
- }
- .target-equipment {
- margin-top: 4px;
- padding-top: 4px;
- border-top: 1px dashed rgba(14, 165, 233, 0.2);
- }
- }
- .target-hint {
- padding: 4px 6px;
- border-radius: 3px;
- background-color: rgba(15, 23, 42, 0.5);
- border: 1px solid rgba(234, 179, 8, 0.3);
- }
- /* 装备详情样式 */
- .equipment-detail {
- background-color: rgba(15, 23, 42, 0.5);
- border-radius: 3px;
- }
- .detail-item {
- margin-bottom: 12px;
- .detail-label {
- color: #94a3b8;
- margin-bottom: 4px;
- }
- .detail-value {
- color: #e0f2fe;
- }
- }
- /* 靶标-装备分配关系表格样式 */
- ::v-deep .el-table {
- background-color: transparent;
- color: #e0f2fe;
- .el-table__empty-text {
- color: #94a3b8;
- }
- .el-table__row:hover > td {
- background-color: rgba(30, 58, 138, 0.2);
- }
- }
- /* 任务概览样式:紧凑布局 */
- .preview-section {
- background-color: rgba(15, 23, 42, 0.7);
- border: 1px solid rgba(14, 165, 233, 0.3);
- border-radius: 3px;
- overflow: hidden;
- transition: all 0.3s;
- &:hover {
- box-shadow: 0 3px 15px rgba(14, 165, 233, 0.1);
- }
- }
- .preview-section h4 {
- color: #bae6fd;
- border-bottom-color: rgba(14, 165, 233, 0.2);
- display: flex;
- align-items: center;
- }
- .overview-stats {
- display: flex;
- flex-direction: column;
- gap: 5px;
- }
- .stat-row-compact {
- display: flex;
- justify-content: space-between;
- align-items: center;
- }
- .stat-label-compact {
- color: #94a3b8;
- }
- .stat-value-compact {
- color: #60a5fa;
- }
- /* 时间轴样式:紧凑布局 */
- .timeline-container {
- padding-left: 10px;
- }
- .timeline-line {
- background-color: rgba(14, 165, 233, 0.3);
- left: 8px;
- }
- .timeline-item-compact {
- position: relative;
- transition: all 0.3s;
- padding-bottom: 5px;
- &:hover {
- transform: translateX(3px);
- }
- }
- .timeline-content-compact {
- background-color: rgba(15, 23, 42, 0.6);
- border: 1px solid rgba(14, 165, 233, 0.2);
- border-radius: 3px;
- padding: 3px 5px;
- }
- .timeline-time {
- color: #60a5fa;
- }
- .timeline-title {
- color: #bae6fd;
- }
- .timeline-description {
- color: #94a3b8;
- line-height: 1.5;
- }
- .timeline-dot {
- box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.8);
- }
- /* 对话框样式:军事风格适配 */
- ::v-deep .target-dialog, ::v-deep .equipment-dialog {
- .el-dialog {
- background-color: rgba(15, 23, 42, 0.95);
- border: 1px solid rgba(14, 165, 233, 0.3);
- border-radius: 4px;
- box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
- }
- .el-dialog__header {
- background-color: rgba(30, 58, 138, 0.6);
- border-bottom: 1px solid rgba(14, 165, 233, 0.3);
- .el-dialog__title {
- color: #bae6fd;
- }
- }
- .el-dialog__body {
- background-color: rgba(15, 23, 42, 0.95);
- color: #e0f2fe;
- }
- .el-dialog__footer {
- background-color: rgba(15, 23, 42, 0.95);
- border-top: 1px solid rgba(14, 165, 233, 0.3);
- }
- }
- /* 按钮样式优化:军事风格突出 */
- ::v-deep .el-button {
- border-radius: 3px;
- border: none;
- &.el-button--primary {
- background-color: #1e40af;
- color: white;
- &:hover {
- background-color: #3b82f6;
- }
- }
- &.el-button--success {
- background-color: #065f46;
- color: white;
- &:hover {
- background-color: #16a34a;
- }
- }
- &.el-button--warning {
- background-color: #92400e;
- color: white;
- &:hover {
- background-color: #d97706;
- }
- }
- &.el-button--text {
- color: #94a3b8;
- &:hover {
- color: #bae6fd;
- background-color: rgba(148, 163, 184, 0.1);
- }
- }
- }
- /* 滑块样式:军事风格适配 */
- ::v-deep .el-slider {
- .el-slider__runway {
- background-color: rgba(51, 65, 85, 0.5);
- }
- .el-slider__bar {
- background-color: #3b82f6;
- }
- .el-slider__button {
- border-color: #3b82f6;
- }
- }
- /* 消息提示样式:军事风格适配 */
- ::v-deep .el-message {
- background-color: rgba(30, 58, 138, 0.8);
- border-color: rgba(14, 165, 233, 0.3);
- color: #e0f2fe;
- }
- /* 确认框样式:军事风格适配 */
- ::v-deep .el-dialog--confirm {
- .el-dialog__body {
- color: #e0f2fe;
- }
- }
- /* 全局容器背景色确认 */
- ::v-deep .el-container {
- background: transparent;
- }
- /* 树形控件样式适配 */
- ::v-deep .el-tree {
- background-color: transparent;
- .el-tree-node__content {
- color: #e0f2fe;
- height: 32px;
- &:hover {
- background-color: rgba(30, 58, 138, 0.3);
- }
- }
- .el-tree-node.is-current > .el-tree-node__content {
- background-color: rgba(59, 130, 246, 0.2);
- color: #60a5fa;
- }
- .el-tree-node__expand-icon {
- color: #94a3b8;
- &:hover {
- color: #60a5fa;
- }
- }
- }
- /* 大屏响应式优化 */
- @media (max-width: 1600px) {
- .equipment-config-container {
- grid-template-columns: 1fr 2fr;
- }
- }
- @media (max-width: 1200px) {
- .equipment-config-container {
- grid-template-columns: 1fr;
- }
- .equipment-status-grid {
- grid-template-columns: repeat(2, 1fr);
- }
- }
- </style>
|