fix: enforce application limits and signature format
This commit is contained in:
@@ -3,6 +3,7 @@ import { Check, Download, FileText, Plus, Search, Send, Trash2 } from 'lucide-re
|
||||
import { Button, DateTimeInput, Input, Modal, Select, Tag, Textarea } from '@/components/ui';
|
||||
import { clientApi, type ClientSmsApplication, type ClientSmsSignatureView, type ClientSmsTemplate, type ImportPreviewResponse, type SmsBatchTask } from '@/api/adminApi';
|
||||
import { formatCents } from '@/utils/currency';
|
||||
import { replaceLeadingSmsSignature } from '@/utils/smsSignature';
|
||||
|
||||
type Recipient = {
|
||||
id: string;
|
||||
@@ -71,7 +72,7 @@ export function ClientSendPage() {
|
||||
const importedValidCount = importPreview?.validCount ?? 0;
|
||||
const receiverCount = receiverMode === 'manual' ? validRecipients.length : importedValidCount;
|
||||
const previewText = selectedSignature && messageContent
|
||||
? `【${selectedSignature.name}】${messageContent}`
|
||||
? replaceLeadingSmsSignature(messageContent, selectedSignature.name)
|
||||
: messageContent;
|
||||
const wordCount = previewText.length;
|
||||
const smsParts = wordCount > 0 ? Math.max(1, Math.ceil(wordCount / 70)) : 0;
|
||||
|
||||
Reference in New Issue
Block a user