Ver Fonte

增加cps配置项

dodo hold há 2 anos atrás
pai
commit
56fe594c63
3 ficheiros alterados com 101 adições e 5 exclusões
  1. 3 0
      src/api/taobao.ts
  2. 83 3
      src/views/jd/list.vue
  3. 15 2
      src/views/settings/config.vue

+ 3 - 0
src/api/taobao.ts

@@ -23,6 +23,9 @@ export interface UpdateConfigModel {
     
     jd_limit_per_ip_24h: number;
     tk_limit_per_ip_24h: number;
+    
+    cpsIgnorePercentageCity: string;
+    cps_limit_per_ip_24h: number;
 }
 
 

+ 83 - 3
src/views/jd/list.vue

@@ -107,8 +107,8 @@
             </a-row>
 
             <a-table row-key="id" :loading="loading" :pagination="pagination" :summary="true" summary-text="汇总"
-                :columns="(cloneColumns as TableColumnData[])" :data="renderData" :bordered="false" :size="size"
-                @page-change="onPageChange">
+                :columns="(cloneColumns as TableColumnData[])" :data="renderData" :bordered="{ headerCell: true }"
+                :size="size" @page-change="onPageChange">
                 <template #index="{ record }">
                     {{ record.id }}
                 </template>
@@ -192,6 +192,27 @@
                     <div style="margin:10px auto" v-if="column.slotName == 'daily_calls_limit'">
                         {{ numberFormat(record.current_daily_calls) }}
                     </div>
+
+
+                    <template v-if="column.dataIndex == 'today_clickNum' ||
+                        column.dataIndex == 'today_orderNum' ||
+                        column.dataIndex == 'today_finishOrderNum' ||
+                        column.dataIndex == 'today_finishCosPrice'">
+
+                        <div>{{ numberFormat(record[column.dataIndex]) }}</div>
+                    </template>
+
+
+
+                    <template v-if="column.dataIndex == 'today_cosPrice' ||
+                        column.dataIndex == 'today_finishCosFee' ||
+                        column.dataIndex == 'today_cosFee'">
+
+                        <div>{{ amountFormat(record[column.dataIndex]) }}</div>
+                    </template>
+
+
+
                 </template>
                 <template #time_range="{ record }">
                     <WorkHourModel :record="record" @change="search" />
@@ -239,7 +260,7 @@ const formModel = ref(generateFormModel());
 const cloneColumns = ref<Column[]>([]);
 const showColumns = ref<Column[]>([]);
 
-const size = ref<SizeProps>('mini');
+const size = ref<SizeProps>('small');
 
 const basePagination: Pagination = {
     current: 1,
@@ -287,16 +308,75 @@ const columns = computed<TableColumnData[]>(() => [
         align: 'right',
         width: 200,
     },
+    {
+        title: '当日推广效果',
+        children: [
+            {
+                title: '点击量',
+                dataIndex: 'today_clickNum',
+                width: 100,
+                align: 'right',
+                render: (e: any) => numberFormat(e.record.today_clickNum)
+            },
+            {
+                title: '有效订单',
+                dataIndex: 'today_orderNum',
+                width: 100,
+                align: 'right',
+                render: (e: any) => numberFormat(e.record.today_orderNum)
+            },
+            {
+                title: '订单金额',
+                dataIndex: 'today_cosPrice',
+                width: 150,
+                align: 'right',
+                render: (e: any) => amountFormat(e.record.today_cosPrice)
+            },
+            // {
+            //     title: '完成收益',
+            //     dataIndex: 'today_finishCosFee',
+            //     width: 100,
+            //     align: 'right',
+            //     render: (e: any) => amountFormat(e.record.today_finishCosFee)
+            // },
+            // {
+            //     title: '完成订单量',
+            //     dataIndex: 'today_finishOrderNum',
+            //     width: 100,
+            //     align: 'right',
+            //     render: (e: any) => numberFormat(e.record.today_finishOrderNum)
+            // },
+            // {
+            //     title: '完成订单量',
+            //     dataIndex: 'today_finishCosPrice',
+            //     width: 100,
+            //     align: 'right',
+            //     render: (e: any) => numberFormat(e.record.today_finishCosPrice)
+            // },
+            {
+                title: '预估收入',
+                dataIndex: 'today_cosFee',
+                width: 150,
+                align: 'right',
+                render: (e: any) => amountFormat(e.record.today_cosFee)
+            },
+
+            // 
+
+        ]
+    },
     {
         title: '小时调用',
         slotName: 'hourly_calls_limit',
         dataIndex: 'current_hourly_calls',
+        align: 'right',
         width: 120,
     },
     {
         title: '当日调用',
         slotName: 'daily_calls_limit',
         dataIndex: 'current_daily_calls',
+        align: 'right',
         width: 150,
     },
     {

+ 15 - 2
src/views/settings/config.vue

@@ -38,7 +38,7 @@
                             </a-form-item>
 
 
-                            
+
                             <a-form-item field="fake_click_min" label="补点击次数" :rules="[{ required: true }]">
                                 <a-input-number v-model="formData.fake_click_min" :min="0" /> -
                                 <a-input-number v-model="formData.fake_click_max" :min="0" />
@@ -55,13 +55,15 @@
                             </a-form-item>
 
 
+
                             <a-form-item field="rt_max" label="转链超时" :rules="[{ required: true }]">
                                 <a-input-number v-model="formData.rt_max" :min="500" placeholder="转链API最长超时时间,单位毫秒" />
                             </a-form-item>
 
 
                             <a-form-item field="similar_timeout" label="搜同款超时" :rules="[{ required: true }]">
-                                <a-input-number v-model="formData.similar_timeout" :min="1000" placeholder="搜同款API最长超时时间,单位毫秒" />
+                                <a-input-number v-model="formData.similar_timeout" :min="1000"
+                                    placeholder="搜同款API最长超时时间,单位毫秒" />
                             </a-form-item>
 
 
@@ -88,6 +90,15 @@
                                     </a-button>
                                 </template>
                             </a-form-item>
+                            <a-divider />
+                            <a-form-item field="cpsIgnorePercentageCity" label="CPS流量控制-城市" :rules="[{ required: true }]">
+                                <a-input v-model="formData.cpsIgnorePercentageCity" />
+                            </a-form-item>
+
+                            <a-form-item field="cps_limit_per_ip_24h" label="24小时转链次数(TK)" :rules="[{ required: true }]">
+                                <a-input-number v-model="formData.cps_limit_per_ip_24h" :min="0"
+                                    placeholder="同ip在24小时内可转链的次数。" />
+                            </a-form-item>
                             <a-form-item>
                                 <a-space>
                                     <a-button type="primary" @click="validate">
@@ -152,6 +163,8 @@ const formData = ref<UpdateConfigModel>({
     multi_token_regular: '',
     jd_limit_per_ip_24h: 0,
     tk_limit_per_ip_24h: 0,
+    cpsIgnorePercentageCity: '',
+    cps_limit_per_ip_24h: 0,
 });
 
 const showRegularTester = ref<boolean>(false);