一次大的提交
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
/// 全局颜色常量
|
||||
class AppColors {
|
||||
@@ -27,26 +27,32 @@ class AppDimensions {
|
||||
|
||||
/// 上报类型枚举
|
||||
enum ReportType {
|
||||
deviceFault('report.device_fault', Icons.notifications_active),
|
||||
patrolRecord('report.patrol_record', Icons.description),
|
||||
hiddenDanger('report.hidden_danger', Icons.shield),
|
||||
defectReport('report.defect_report', Icons.build);
|
||||
mowerError('MOWER_ERROR', '割草机故障', Icons.notifications_active),
|
||||
uavError('UAV_ERROR', '无人机故障', Icons.flight),
|
||||
inspectionTask('INSPECTION_TASK', '巡检', Icons.search),
|
||||
componentDefect('COMPONENT_DEFECT', '光伏组件故障', Icons.power),
|
||||
cleanTask('CLEAN_TASK', '清洗任务', Icons.cleaning_services),
|
||||
maintainTask('MAINTAIN_TASK', '维护任务', Icons.handyman),
|
||||
repairTask('REPAIR_TASK', '维修任务', Icons.build),
|
||||
other('OTHER', '其他', Icons.more_horiz);
|
||||
|
||||
final String labelKey;
|
||||
final String orderType;
|
||||
final String label;
|
||||
final IconData icon;
|
||||
|
||||
const ReportType(this.labelKey, this.icon);
|
||||
const ReportType(this.orderType, this.label, this.icon);
|
||||
}
|
||||
|
||||
/// 问题等级枚举
|
||||
enum ProblemLevel {
|
||||
normal('report.normal', Color(0xFF86909C), Color(0xFFE5E6EB)),
|
||||
important('report.important', Color(0xFFFF7D00), Color(0xFFE5E6EB)),
|
||||
urgent('report.urgent', Color(0xFFF53F3F), Color(0xFFF53F3F));
|
||||
info('INFO', '信息', Color(0xFF165DFF), Color(0xFF165DFF)),
|
||||
warning('WARNING', '警告', Color(0xFFFF7D00), Color(0xFFFF7D00)),
|
||||
error('ERROR', '错误', Color(0xFFF53F3F), Color(0xFFF53F3F));
|
||||
|
||||
final String labelKey;
|
||||
final String level;
|
||||
final String label;
|
||||
final Color textColor;
|
||||
final Color borderColor;
|
||||
|
||||
const ProblemLevel(this.labelKey, this.textColor, this.borderColor);
|
||||
const ProblemLevel(this.level, this.label, this.textColor, this.borderColor);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user