feat: small fix
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m12s

This commit is contained in:
luo
2026-07-29 11:36:34 +08:00
parent 827de02f2b
commit 4394ae0f78
10 changed files with 58 additions and 64 deletions

View File

@@ -291,7 +291,6 @@
<div class="dialog-footer">
<ElButton @click="wecomBindingDialogVisible = false">取消</ElButton>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.binding"
type="primary"
:loading="wecomBindingSubmitting"
@click="submitWecomBinding"

View File

@@ -48,7 +48,7 @@
<ElDrawer
v-model="detailDrawerVisible"
:title="`${currentShop?.shop_name || ''} - 佣金详情`"
size="60%"
size="65%"
destroy-on-close
>
<ElTabs v-model="activeTab" class="detail-tabs">
@@ -990,14 +990,6 @@
const getActions = (row: ShopFundSummaryItem) => {
const actions: any[] = []
if (hasAuth('agent_commission:detail')) {
actions.push({
label: '查看详情',
handler: () => showDetail(row),
type: 'primary'
})
}
if (hasAuth('shop:credit_limit_manage')) {
actions.push({
label: '调整额度',

View File

@@ -131,15 +131,19 @@
<div class="package-config-name" :title="pkg.package_name || ''">
{{ pkg.package_name || '套餐名称不可用' }}
</div>
<ElInputNumber
v-model="pkg.cost_price_yuan"
:min="pkg.original_cost_price || 0"
:max="getPackageCostPriceMax(pkg)"
:precision="2"
:step="0.01"
:controls="false"
placeholder="成本价(元)"
/>
<div class="package-config-cost">
<span class="package-config-field-label">套餐成本价</span>
<ElInputNumber
v-model="pkg.cost_price_yuan"
:min="pkg.original_cost_price || 0"
:max="getPackageCostPriceMax(pkg)"
:precision="2"
:step="0.01"
:controls="false"
placeholder="请输入成本价"
style="width: 150px"
/>
</div>
</div>
</div>
</ElFormItem>
@@ -759,7 +763,10 @@
remove: true
}
]
await ShopSeriesGrantService.manageGrantPackages(grantId.value, { packages })
await ShopSeriesGrantService.manageGrantPackages(grantId.value, {
expiry_base_override: row.expiry_base_override ?? null,
packages
})
await fetchPackageList()
} catch (error) {
console.error(error)
@@ -858,6 +865,19 @@
flex: 1;
}
.package-config-cost {
display: flex;
flex-shrink: 0;
gap: 8px;
align-items: center;
}
.package-config-field-label {
color: var(--el-text-color-secondary);
font-size: 13px;
white-space: nowrap;
}
.ellipsis-value {
display: block;
width: 260px;

View File

@@ -76,22 +76,8 @@
<template #footer>
<div class="dialog-footer">
<ElButton @click="visible = false">取消</ElButton>
<ElButton
v-if="isEdit"
v-permission="JULY_PERMISSIONS.wecom.application"
:loading="testing"
@click="testApplication"
>
测试连接
</ElButton>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.application"
type="primary"
:loading="saving"
@click="saveApplication"
>
保存应用
</ElButton>
<ElButton v-if="isEdit" :loading="testing" @click="testApplication"> 测试连接 </ElButton>
<ElButton type="primary" :loading="saving" @click="saveApplication"> 保存应用 </ElButton>
</div>
</template>
</ElDialog>
@@ -102,7 +88,6 @@
import { ElMessage } from 'element-plus'
import type { FormInstance, FormRules } from 'element-plus'
import { WecomService } from '@/api/modules'
import { JULY_PERMISSIONS } from '@/config/constants'
import type { WecomApplication } from '@/types/api'
defineOptions({ name: 'WecomApplicationFormDialog' })

View File

@@ -9,7 +9,7 @@
>
<template #left>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.application"
v-permission="JULY_PERMISSIONS.wecom.applicationCreate"
type="primary"
@click="openCreateDialog"
>
@@ -173,19 +173,21 @@
const getActions = (row: WecomApplication) => {
const actions: any[] = []
if (hasAuth(JULY_PERMISSIONS.wecom.application)) {
if (hasAuth(JULY_PERMISSIONS.wecom.applicationTest)) {
actions.push({
label: '测试连接',
handler: () => testApplication(row.id),
type: 'primary'
})
}
if (hasAuth(JULY_PERMISSIONS.wecom.applicationEdit)) {
actions.push({
label: '编辑配置',
handler: () => openEditDialog(row),
type: 'primary'
})
}
if (hasAuth(JULY_PERMISSIONS.wecom.member)) {
if (hasAuth(JULY_PERMISSIONS.wecom.memberManage)) {
actions.push({
label: '成员管理',
handler: () => goToMembers(row.id),

View File

@@ -13,7 +13,7 @@
<div class="members-toolbar">
<div class="toolbar-actions">
<ElButton
v-permission="JULY_PERMISSIONS.wecom.member"
v-permission="JULY_PERMISSIONS.wecom.memberSync"
:disabled="!selectedApplicationId"
:loading="syncing"
type="primary"
@@ -42,7 +42,7 @@
</ElTag>
<ElTag
v-else
v-permission="JULY_PERMISSIONS.wecom.member"
v-permission="JULY_PERMISSIONS.wecom.memberDefaultCreator"
class="member-card__action-tag"
type="primary"
effect="plain"

View File

@@ -9,7 +9,7 @@
>
<template #left>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.scene"
v-permission="JULY_PERMISSIONS.wecom.sceneCreate"
type="primary"
@click="createScene"
>
@@ -88,11 +88,7 @@
<ElFormItem label="模板 ID" required>
<ElInput v-model="sceneForm.template_id" placeholder="请输入企微后台模板 ID">
<template #append>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.scene"
:loading="inspectingTemplate"
@click="syncTemplate()"
>
<ElButton :loading="inspectingTemplate" @click="syncTemplate()">
同步模板
</ElButton>
</template>
@@ -173,14 +169,7 @@
<div class="dialog-footer">
<ElButton @click="editorVisible = false">取消</ElButton>
<ElButton @click="createScene">清空表单</ElButton>
<ElButton
v-permission="JULY_PERMISSIONS.wecom.scene"
type="primary"
:loading="saving"
@click="saveScene"
>
保存并校验
</ElButton>
<ElButton type="primary" :loading="saving" @click="saveScene"> 保存并校验 </ElButton>
</div>
</template>
</ElDialog>
@@ -490,7 +479,7 @@
}
const getActions = (row: WecomScene) => {
if (!hasAuth(JULY_PERMISSIONS.wecom.scene)) return []
if (!hasAuth(JULY_PERMISSIONS.wecom.sceneEdit)) return []
return [
{
label: '编辑',

View File

@@ -307,12 +307,14 @@
{
prop: 'carrier_code',
label: '运营商编码',
minWidth: 160
minWidth: 160,
showOverflowTooltip: true
},
{
prop: 'carrier_name',
label: '运营商名称',
minWidth: 150
minWidth: 150,
showOverflowTooltip: true
},
{
prop: 'carrier_type',

View File

@@ -46,7 +46,7 @@
:title="dialogType === 'add' ? '新增角色' : '编辑角色'"
width="30%"
>
<ElForm ref="formRef" :model="form" :rules="rules" label-width="160px">
<ElForm ref="formRef" :model="form" :rules="rules" label-width="100px">
<ElFormItem label="角色名称" prop="role_name">
<ElInput v-model="form.role_name" placeholder="请输入角色名称" />
</ElFormItem>
@@ -81,7 +81,7 @@
/>
</ElFormItem>
<template v-if="isCustomerRoleForm">
<ElFormItem label="新建代理默认信用">
<ElFormItem label="代理默认信用">
<ElSwitch
v-model="form.credit_enabled"
@change="handleDefaultCreditEnabledChange"