feat: icon

This commit is contained in:
xingyu4j
2025-11-05 18:27:17 +08:00
parent dec939ee30
commit f60069d662
5 changed files with 21 additions and 18 deletions

View File

@@ -161,11 +161,11 @@ function removeConditionGroup() {
@click="addSubGroup"
:disabled="(trigger.conditionGroups?.length || 0) >= maxSubGroups"
>
<IconifyIcon icon="ep:plus" />
<IconifyIcon icon="lucide:plus" />
添加子条件组
</Button>
<Button danger size="small" text @click="removeConditionGroup">
<IconifyIcon icon="ep:delete" />
<IconifyIcon icon="lucide:trash-2" />
删除条件组
</Button>
</div>
@@ -215,7 +215,7 @@ function removeConditionGroup() {
@click="removeSubGroup(subGroupIndex)"
class="hover:bg-red-50"
>
<IconifyIcon icon="ep:delete" />
<IconifyIcon icon="lucide:trash-2" />
删除组
</Button>
</div>
@@ -258,7 +258,7 @@ function removeConditionGroup() {
class="p-24px rounded-8px border-2 border-dashed border-orange-200 bg-orange-50 text-center"
>
<div class="gap-12px flex flex-col items-center">
<IconifyIcon icon="ep:plus" class="text-32px text-orange-400" />
<IconifyIcon icon="lucide:plus" class="text-32px text-orange-400" />
<div class="text-orange-600">
<p class="text-14px font-500 mb-4px">暂无子条件组</p>
<p class="text-12px">点击上方"添加子条件组"按钮开始配置</p>

View File

@@ -136,7 +136,7 @@ function updateCondition(index: number, condition: TriggerCondition) {
v-if="subGroup!.length > 1"
class="hover:bg-red-50"
>
<IconifyIcon icon="ep:delete" />
<IconifyIcon icon="lucide:trash-2" />
</Button>
</div>

View File

@@ -100,7 +100,7 @@ function removeAction(index: number) {
* @param type 执行器类型
*/
function updateActionType(index: number, type: number) {
actions.value[index].type = type.toString();
actions.value[index]!.type = type.toString();
onActionTypeChange(actions.value[index] as Action, type);
}
@@ -119,7 +119,7 @@ function updateAction(index: number, action: Action) {
* @param alertConfigId 告警配置ID
*/
function updateActionAlertConfig(index: number, alertConfigId?: number) {
actions.value[index].alertConfigId = alertConfigId;
actions.value[index]!.alertConfigId = alertConfigId;
if (actions.value[index]) {
actions.value[index].alertConfigId = alertConfigId;
}
@@ -220,7 +220,7 @@ function onActionTypeChange(action: Action, type: any) {
@click="removeAction(index)"
class="hover:bg-red-50"
>
<IconifyIcon icon="ep:delete" />
<IconifyIcon icon="lucide:trash-2" />
删除
</Button>
</div>

View File

@@ -71,7 +71,7 @@ function removeTrigger(index: number) {
* @param type 触发器类型
*/
function updateTriggerType(index: number, type: number) {
triggers.value[index].type = type;
triggers.value[index]!.type = type.toString();
onTriggerTypeChange(index, type);
}
@@ -90,7 +90,7 @@ function updateTriggerDeviceConfig(index: number, newTrigger: Trigger) {
* @param cronExpression CRON 表达式
*/
function updateTriggerCronConfig(index: number, cronExpression?: string) {
triggers.value[index].cronExpression = cronExpression;
triggers.value[index]!.cronExpression = cronExpression;
}
/**
@@ -99,7 +99,7 @@ function updateTriggerCronConfig(index: number, cronExpression?: string) {
* @param _ 触发器类型(未使用)
*/
function onTriggerTypeChange(index: number, _: number) {
const triggerItem = triggers.value[index];
const triggerItem = triggers.value[index]!;
triggerItem.productId = undefined;
triggerItem.deviceId = undefined;
triggerItem.identifier = undefined;
@@ -127,7 +127,7 @@ onMounted(() => {
<Tag size="small" type="info"> {{ triggers.length }} 个触发器 </Tag>
</div>
<Button type="primary" size="small" @click="addTrigger">
<IconifyIcon icon="ep:plus" />
<IconifyIcon icon="lucide:plus" />
添加触发器
</Button>
</div>
@@ -173,7 +173,7 @@ onMounted(() => {
@click="removeTrigger(index)"
class="hover:bg-red-50"
>
<IconifyIcon icon="ep:delete" />
<IconifyIcon icon="lucide:trash-2" />
删除
</Button>
</div>
@@ -203,7 +203,10 @@ onMounted(() => {
<div
class="gap-8px p-12px px-16px rounded-6px border-primary bg-background flex items-center border"
>
<IconifyIcon icon="ep:timer" class="text-18px text-danger" />
<IconifyIcon
icon="lucide:timer"
class="text-18px text-danger"
/>
<span class="text-14px font-500 text-primary">
定时触发配置
</span>

View File

@@ -14,7 +14,7 @@ const router = useRouter();
const menuList = [
{
name: '用户管理',
icon: 'ep:user-filled',
icon: 'lucide:user',
bgColor: 'bg-red-400',
routerName: 'MemberUser',
},
@@ -26,7 +26,7 @@ const menuList = [
},
{
name: '订单管理',
icon: 'ep:list',
icon: 'lucide:list',
bgColor: 'bg-yellow-500',
routerName: 'TradeOrder',
},
@@ -44,13 +44,13 @@ const menuList = [
},
{
name: '优惠券',
icon: 'ep:ticket',
icon: 'lucide:ticket',
bgColor: 'bg-blue-500',
routerName: 'PromotionCoupon',
},
{
name: '拼团活动',
icon: 'fa:group',
icon: 'lucide:users',
bgColor: 'bg-purple-500',
routerName: 'PromotionBargainActivity',
},