Sfoglia il codice sorgente

Merge remote-tracking branch 'origin/master'

# Conflicts:
#	generate-code/cli.js
yu jie 4 anni fa
parent
commit
42cc0cb3ee
81 ha cambiato i file con 288 aggiunte e 9 eliminazioni
  1. 104 0
      generate-code/cli.js
  2. 83 0
      generate-code/template.js
  3. 0 0
      generate-code/templates/model.js
  4. 85 0
      generate-code/templates/table.js
  5. 1 1
      public/config/app.config.json
  6. 0 0
      src/pages/business/exposure/exposure_history/index.vue
  7. 0 0
      src/pages/business/exposure/exposure_realtime/index.vue
  8. 0 0
      src/pages/business/exposure/exposure_spot/index.vue
  9. 0 0
      src/pages/business/plan/plan_audit/index.vue
  10. 0 0
      src/pages/business/plan/plan_running/index.vue
  11. 0 0
      src/pages/business/plan/plan_uncommitted/index.vue
  12. 0 0
      src/pages/business/purchase/purchase_all/index.vue
  13. 0 0
      src/pages/business/purchase/purchase_pending/index.vue
  14. 0 0
      src/pages/business/purchase/purchase_performance/index.vue
  15. 0 0
      src/pages/business/sell/sell_all/index.vue
  16. 0 0
      src/pages/business/sell/sell_pending/index.vue
  17. 0 0
      src/pages/business/sell/sell_performance/index.vue
  18. 0 0
      src/pages/info/account_info/account_info_business/index.vue
  19. 0 0
      src/pages/info/account_info/account_info_futures/index.vue
  20. 0 0
      src/pages/info/account_info/account_info_manager/index.vue
  21. 0 0
      src/pages/info/account_info/account_info_trade/index.vue
  22. 0 0
      src/pages/info/custom_info/custom_info_checkpending/index.vue
  23. 0 0
      src/pages/info/custom_info/custom_info_disabled/index.vue
  24. 0 0
      src/pages/info/custom_info/custom_info_normal/index.vue
  25. 0 0
      src/pages/info/custom_info/custom_info_unsubmit/index.vue
  26. 0 0
      src/pages/info/goods_info/goods_info_hedge/index.vue
  27. 0 0
      src/pages/info/goods_info/goods_info_spot/index.vue
  28. 0 0
      src/pages/info/spot_contract/spot_contract_checkpending/index.vue
  29. 0 0
      src/pages/info/spot_contract/spot_contract_finished/index.vue
  30. 0 0
      src/pages/info/spot_contract/spot_contract_performance/index.vue
  31. 0 0
      src/pages/info/spot_contract/spot_contract_unsubmitted/index.vue
  32. 0 0
      src/pages/info/warehouse_info/warehouse_info_disabled/index.vue
  33. 0 0
      src/pages/info/warehouse_info/warehouse_info_normal/index.vue
  34. 0 0
      src/pages/manage/business_review/business_review_settlement/index.vue
  35. 0 0
      src/pages/manage/business_review/business_review_someprice/index.vue
  36. 0 0
      src/pages/manage/finance_review/finance_review_funds/index.vue
  37. 0 0
      src/pages/manage/finance_review/finance_review_invoice/index.vue
  38. 0 0
      src/pages/manage/inventory_review/inventory_review_checkin/index.vue
  39. 0 0
      src/pages/manage/inventory_review/inventory_review_checkout/index.vue
  40. 0 0
      src/pages/market/futures/closedetail/index.vue
  41. 0 0
      src/pages/market/futures/dominant_contract/index.vue
  42. 0 0
      src/pages/market/futures/main_contract/index.vue
  43. 0 0
      src/pages/market/futures/night_plate/index.vue
  44. 0 0
      src/pages/market/futures/orderdetail/index.vue
  45. 0 0
      src/pages/market/futures/position/index.vue
  46. 0 0
      src/pages/market/futures/tradedetail/index.vue
  47. 0 0
      src/pages/platinum/platinum_agents_and_stores/platinum_agents_and_stores_tab/index.vue
  48. 0 0
      src/pages/platinum/platinum_agreement/platinum_agreement_tab/index.vue
  49. 0 0
      src/pages/platinum/platinum_contract_commodity_suspension/platinum_contract_commodity_suspension_tab/index.vue
  50. 0 0
      src/pages/platinum/platinum_contract_goods/platinum_contract_goods_tab/index.vue
  51. 0 0
      src/pages/platinum/platinum_customer_info/platinum_custom_info_normal/index.vue
  52. 0 0
      src/pages/platinum/platinum_customer_info/platinum_customer_info_stop/index.vue
  53. 0 0
      src/pages/platinum/platinum_customer_info/platinum_customer_info_unsubmit/index.vue
  54. 0 0
      src/pages/platinum/platinum_document_query/platinum_document_query_order/index.vue
  55. 0 0
      src/pages/platinum/platinum_document_query/platinum_document_query_position/index.vue
  56. 0 0
      src/pages/platinum/platinum_document_query/platinum_document_query_success/index.vue
  57. 0 0
      src/pages/platinum/platinum_document_query/platinum_document_query_waiting/index.vue
  58. 0 0
      src/pages/platinum/platinum_financing_information/platinum_financing_information_tab/index.vue
  59. 0 0
      src/pages/platinum/platinum_fixed_investment_price_query/platinum_fixed_investment_price_query_tab/index.vue
  60. 0 0
      src/pages/platinum/platinum_fixed_investment_query/platinum_fixed_investment_flow_query/index.vue
  61. 0 0
      src/pages/platinum/platinum_fixed_investment_query/platinum_fixed_investment_plan_query/index.vue
  62. 0 0
      src/pages/platinum/platinum_pick_goods_management/platinum_pick_goods_management_tab/index.vue
  63. 0 0
      src/pages/platinum/platinum_pick_query/platinum_pick_query_tab/index.vue
  64. 0 0
      src/pages/platinum/platinum_recharge_withdrawal_review/platinum_recharge_review_tab/index.vue
  65. 0 0
      src/pages/platinum/platinum_recharge_withdrawal_review/platinum_withdrawal_review_tab/index.vue
  66. 0 0
      src/pages/platinum/platinum_spot_and_price/platinum_spot_and_price_tab/index.vue
  67. 0 0
      src/pages/report/exposure_report/exposure_report_exposure/index.vue
  68. 0 0
      src/pages/report/finance_report/finance_report_finance/index.vue
  69. 0 0
      src/pages/report/future_report/future_report_future/index.vue
  70. 0 0
      src/pages/report/inventory_report/inventory_report_inventory_category/index.vue
  71. 0 0
      src/pages/report/inventory_report/inventory_report_warehouse/index.vue
  72. 0 0
      src/pages/report/spot_report/spot_report_spot/index.vue
  73. 0 0
      src/pages/report/sum_pl_report/sum_pl_report_sum_pl/index.vue
  74. 0 0
      src/pages/search/inventory/inventory_applyrecord/index.vue
  75. 0 0
      src/pages/search/inventory/inventory_current/index.vue
  76. 0 0
      src/pages/search/outaccount_status/outaccount_status_status/index.vue
  77. 2 0
      src/services/bus/login.ts
  78. 2 0
      src/services/request/serviceURL.ts
  79. 5 4
      src/views/platinum/platinum_capital_flow/platinum_capital_flow_tab/index.vue
  80. 1 0
      src/views/platinum/platinum_pick_query/list/tab/index.vue
  81. 5 4
      src/views/platinum/platinum_promotion_report/platinum_promotion_report_tab/index.vue

+ 104 - 0
generate-code/cli.js

@@ -0,0 +1,104 @@
+#! /usr/bin/env node
+
+// Node Cli 应用入口文件必须要有这样的文件头
+// 如果是 Linux 或者 macos 系统还需要修改此文件的读写权限为 755
+// 具体是通过 chmod 755 cli.js 实现修改
+
+// console.log('working');
+// 脚手架的工作过程
+// 1.通过命令交互询问用户问题
+// 2.根据用户回答的结果生成文件
+
+const inquirer = require('inquirer');
+const fs = require('fs');
+const path = require('path');
+const ejs = require('ejs');
+const { tmpdir } = require('os');
+const { createPartiallyEmittedExpression } = require('typescript');
+
+// 读取json
+const list = JSON.parse(fs.readFileSync('./generate-code/pc_menu_企业风管.json'));
+// 目标目录
+// const destDir = process.cwd();
+const destDir = path.join(process.cwd(), 'src/pages');
+
+//检查某个目录是否存在
+function hasFile(url, code) {
+	const temp = path.join(url, `/${code}`);
+	try {
+		//检查某个目录是否存在
+		fs.statSync(temp);
+		return true;
+	} catch (error) {
+		console.log(temp);
+		console.log(error);
+		return false;
+	}
+}
+
+// 模板目录
+const tempDir = path.join(__dirname, 'templates');
+
+function writeFile(url, code) {
+	if (!hasFile(url, code)) {
+		const temp = path.join(url, `/${code}`);
+		console.log(temp);
+		return fs.promises.mkdir(temp);
+	}
+	return Promise.resolve(false);
+}
+list.forEach((el) => {
+	const { code, children } = el;
+	writeFile(destDir, code).then(() => {
+		if (children) {
+			children.forEach((item) => {
+				writeFile(path.join(destDir, `/${code}`), item.code).then(() => {
+					if (item.children) {
+						item.children.forEach((e) => {
+							const path1 = `/${code}/${item.code}`;
+							writeFile(path.join(destDir, path1), e.code).then(() => {
+								const path2 = `${path1}/${e.code}`;
+								// index.vue
+								if (!hasFile(path.join(destDir, path2), 'index.vue')) {
+									const template = `
+
+									`;
+									fs.writeFileSync(path.join(destDir, `${path2}/index.vue`), template);
+								}
+								// components
+								writeFile(path.join(destDir, `${path2}`), 'components').then(() => {
+									if (e.children) {
+										const path3 = `${path2}/components`;
+										e.children.forEach((ele) => {
+											writeFile(path.join(destDir, path3), ele.code).then((res) => {
+												if (res) {
+													if (
+														!hasFile(
+															path.join(destDir, `${path3}/${ele.code}`),
+															'index.vue'
+														)
+													) {
+														const template = `
+														`;
+														fs.writeFileSync(
+															path.join(destDir, `${path3}${ele.code}/index.vue`),
+															template
+														).then(res => {
+															if (res) {
+
+															}
+														}
+													}
+												}
+											});
+										});
+									}
+								});
+							});
+						});
+					}
+				});
+			});
+		}
+	});
+});

+ 83 - 0
generate-code/template.js

@@ -0,0 +1,83 @@
+const template = `
+<template>
+<!-- ${e.title} -->
+    <div class="${e.code}">
+        <Filter @search="updateColumn" />
+        <a-table :columns="columns"
+                class="srcollYTable"
+                :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }"
+                :pagination="false"
+                :expandedRowKeys="expandedRowKeys"
+                :customRow="Rowclick"
+                rowKey="key"
+                :data-source="tableList">
+        </a-table>
+        <ControlModal :selectedRow="selectedRow"
+            @refresh="getData" />
+        <component :is="componentId"></component>
+    </div>
+</template>
+<script lang="ts">
+import { defineComponent, initData, getTableColumns, getTableEvent, contextMenu, BtnList, _getBtnList, queryTableList } from '@/common/export/table';
+
+export default defineComponent({
+    name: '${e.code}',
+    components: { Filter, contextMenu, BtnList, ControlModal },
+    setup() {
+        // 表头数据
+        const { columns, registerColumn, updateColumn } = getTableColumns();
+        // 表格操作按钮列表
+        const [firstBtn] = _getBtnList('platinum_pick_query_tab', true).value;
+        const btnList = ref<BtnListType[]>([]);
+        const event: TableEventCB = {
+            contextmenuCB: (record: QhjTradeGoodsPickup) => {
+                btnList.value = handleTableList(firstBtn, record);
+            },
+        };
+        // 表格事件
+        const { expandedRowKeys, selectedRow, Rowclick, btnClick } = getTableEvent<QhjTradeGoodsPickup>(event);
+
+        // 表格列表数据
+        const { loading, tableList, queryTable } = queryTableList<QhjTradeGoodsPickup>();
+
+        function getData() {
+            // 获取列表数据
+            queryTable(queryTradeGoodsPickup).then((res) => {
+                tableList.value = res.map((el) => {
+                    return { ...el, key: String(el.takeorderid) };
+                });
+            });
+        }
+
+        // 1:备货中  完成备货
+        // 2:待取货(自提) 确认取货
+        // 4:待收货(邮寄) 上传物流信息、确认收货
+        initData(() => {
+            // 获取列表数据
+            getData();
+            // 注册表头信息 过滤
+            registerColumn('table_pcweb_qhj_pickup_query', ['reqtime', 'pickupgoodsname', 'takeorderstatus', 'goodsname']);
+        });
+
+        return {
+            btnList,
+            columns,
+            getData,
+            updateColumn,
+            expandedRowKeys,
+            selectedRow,
+            Rowclick,
+            firstBtn,
+            loading,
+            tableList,
+            queryTable,
+            btnClick,
+            getPickUpStateName,
+            getTakeStateName,
+            handleTableList,
+        };
+    },
+});
+
+</script >
+`;

+ 0 - 0
src/pages/business/exposure/exposure_futures/index.vue → generate-code/templates/model.js


+ 85 - 0
generate-code/templates/table.js

@@ -0,0 +1,85 @@
+exports function getTableTemplete(e) {
+	return `
+<template>
+<!-- ${e.title} -->
+    <div class="${e.code}">
+        <Filter @search="updateColumn" />
+        <a-table :columns="columns"
+                class="srcollYTable"
+                :scroll="{ x: '100%', y: 'calc(100vh - 163px)' }"
+                :pagination="false"
+                :expandedRowKeys="expandedRowKeys"
+                :customRow="Rowclick"
+                rowKey="key"
+                :data-source="tableList">
+        </a-table>
+        <ControlModal :selectedRow="selectedRow"
+            @refresh="getData" />
+        <component :is="componentId"></component>
+    </div>
+</template>
+<script lang="ts">
+import { defineComponent, initData, getTableColumns, getTableEvent, contextMenu, BtnList, _getBtnList, queryTableList } from '@/common/export/table';
+
+export default defineComponent({
+    name: '${e.code}',
+    components: { Filter, contextMenu, BtnList, ControlModal },
+    setup() {
+        // 表头数据
+        const { columns, registerColumn, updateColumn } = getTableColumns();
+        // 表格操作按钮列表
+        const [firstBtn] = _getBtnList('platinum_pick_query_tab', true).value;
+        const btnList = ref<BtnListType[]>([]);
+        const event: TableEventCB = {
+            contextmenuCB: (record: QhjTradeGoodsPickup) => {
+                btnList.value = handleTableList(firstBtn, record);
+            },
+        };
+        // 表格事件
+        const { expandedRowKeys, selectedRow, Rowclick, btnClick } = getTableEvent<QhjTradeGoodsPickup>(event);
+
+        // 表格列表数据
+        const { loading, tableList, queryTable } = queryTableList<QhjTradeGoodsPickup>();
+
+        function getData() {
+            // 获取列表数据
+            queryTable(queryTradeGoodsPickup).then((res) => {
+                tableList.value = res.map((el) => {
+                    return { ...el, key: String(el.takeorderid) };
+                });
+            });
+        }
+
+        // 1:备货中  完成备货
+        // 2:待取货(自提) 确认取货
+        // 4:待收货(邮寄) 上传物流信息、确认收货
+        initData(() => {
+            // 获取列表数据
+            getData();
+            // 注册表头信息 过滤
+            registerColumn('table_pcweb_qhj_pickup_query', ['reqtime', 'pickupgoodsname', 'takeorderstatus', 'goodsname']);
+        });
+
+        return {
+            btnList,
+            columns,
+            getData,
+            updateColumn,
+            expandedRowKeys,
+            selectedRow,
+            Rowclick,
+            firstBtn,
+            loading,
+            tableList,
+            queryTable,
+            btnClick,
+            getPickUpStateName,
+            getTakeStateName,
+            handleTableList,
+        };
+    },
+});
+
+</script >
+`;
+}

+ 1 - 1
public/config/app.config.json

@@ -1,3 +1,3 @@
 {
-    "apiUrl": "http://218.17.158.45:21001/cfg?key=test_176"
+    "apiUrl": "http://192.168.31.171:8080/cfg?key=test_171"
 }

+ 0 - 0
src/pages/business/exposure/exposure_history/index.vue


+ 0 - 0
src/pages/business/exposure/exposure_realtime/index.vue


+ 0 - 0
src/pages/business/exposure/exposure_spot/index.vue


+ 0 - 0
src/pages/business/plan/plan_audit/index.vue


+ 0 - 0
src/pages/business/plan/plan_running/index.vue


+ 0 - 0
src/pages/business/plan/plan_uncommitted/index.vue


+ 0 - 0
src/pages/business/purchase/purchase_all/index.vue


+ 0 - 0
src/pages/business/purchase/purchase_pending/index.vue


+ 0 - 0
src/pages/business/purchase/purchase_performance/index.vue


+ 0 - 0
src/pages/business/sell/sell_all/index.vue


+ 0 - 0
src/pages/business/sell/sell_pending/index.vue


+ 0 - 0
src/pages/business/sell/sell_performance/index.vue


+ 0 - 0
src/pages/info/account_info/account_info_business/index.vue


+ 0 - 0
src/pages/info/account_info/account_info_futures/index.vue


+ 0 - 0
src/pages/info/account_info/account_info_manager/index.vue


+ 0 - 0
src/pages/info/account_info/account_info_trade/index.vue


+ 0 - 0
src/pages/info/custom_info/custom_info_checkpending/index.vue


+ 0 - 0
src/pages/info/custom_info/custom_info_disabled/index.vue


+ 0 - 0
src/pages/info/custom_info/custom_info_normal/index.vue


+ 0 - 0
src/pages/info/custom_info/custom_info_unsubmit/index.vue


+ 0 - 0
src/pages/info/goods_info/goods_info_hedge/index.vue


+ 0 - 0
src/pages/info/goods_info/goods_info_spot/index.vue


+ 0 - 0
src/pages/info/spot_contract/spot_contract_checkpending/index.vue


+ 0 - 0
src/pages/info/spot_contract/spot_contract_finished/index.vue


+ 0 - 0
src/pages/info/spot_contract/spot_contract_performance/index.vue


+ 0 - 0
src/pages/info/spot_contract/spot_contract_unsubmitted/index.vue


+ 0 - 0
src/pages/info/warehouse_info/warehouse_info_disabled/index.vue


+ 0 - 0
src/pages/info/warehouse_info/warehouse_info_normal/index.vue


+ 0 - 0
src/pages/manage/business_review/business_review_settlement/index.vue


+ 0 - 0
src/pages/manage/business_review/business_review_someprice/index.vue


+ 0 - 0
src/pages/manage/finance_review/finance_review_funds/index.vue


+ 0 - 0
src/pages/manage/finance_review/finance_review_invoice/index.vue


+ 0 - 0
src/pages/manage/inventory_review/inventory_review_checkin/index.vue


+ 0 - 0
src/pages/manage/inventory_review/inventory_review_checkout/index.vue


+ 0 - 0
src/pages/market/futures/closedetail/index.vue


+ 0 - 0
src/pages/market/futures/dominant_contract/index.vue


+ 0 - 0
src/pages/market/futures/main_contract/index.vue


+ 0 - 0
src/pages/market/futures/night_plate/index.vue


+ 0 - 0
src/pages/market/futures/orderdetail/index.vue


+ 0 - 0
src/pages/market/futures/position/index.vue


+ 0 - 0
src/pages/market/futures/tradedetail/index.vue


+ 0 - 0
src/pages/platinum/platinum_agents_and_stores/platinum_agents_and_stores_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_agreement/platinum_agreement_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_contract_commodity_suspension/platinum_contract_commodity_suspension_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_contract_goods/platinum_contract_goods_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_customer_info/platinum_custom_info_normal/index.vue


+ 0 - 0
src/pages/platinum/platinum_customer_info/platinum_customer_info_stop/index.vue


+ 0 - 0
src/pages/platinum/platinum_customer_info/platinum_customer_info_unsubmit/index.vue


+ 0 - 0
src/pages/platinum/platinum_document_query/platinum_document_query_order/index.vue


+ 0 - 0
src/pages/platinum/platinum_document_query/platinum_document_query_position/index.vue


+ 0 - 0
src/pages/platinum/platinum_document_query/platinum_document_query_success/index.vue


+ 0 - 0
src/pages/platinum/platinum_document_query/platinum_document_query_waiting/index.vue


+ 0 - 0
src/pages/platinum/platinum_financing_information/platinum_financing_information_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_fixed_investment_price_query/platinum_fixed_investment_price_query_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_fixed_investment_query/platinum_fixed_investment_flow_query/index.vue


+ 0 - 0
src/pages/platinum/platinum_fixed_investment_query/platinum_fixed_investment_plan_query/index.vue


+ 0 - 0
src/pages/platinum/platinum_pick_goods_management/platinum_pick_goods_management_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_pick_query/platinum_pick_query_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_recharge_withdrawal_review/platinum_recharge_review_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_recharge_withdrawal_review/platinum_withdrawal_review_tab/index.vue


+ 0 - 0
src/pages/platinum/platinum_spot_and_price/platinum_spot_and_price_tab/index.vue


+ 0 - 0
src/pages/report/exposure_report/exposure_report_exposure/index.vue


+ 0 - 0
src/pages/report/finance_report/finance_report_finance/index.vue


+ 0 - 0
src/pages/report/future_report/future_report_future/index.vue


+ 0 - 0
src/pages/report/inventory_report/inventory_report_inventory_category/index.vue


+ 0 - 0
src/pages/report/inventory_report/inventory_report_warehouse/index.vue


+ 0 - 0
src/pages/report/spot_report/spot_report_spot/index.vue


+ 0 - 0
src/pages/report/sum_pl_report/sum_pl_report_sum_pl/index.vue


+ 0 - 0
src/pages/search/inventory/inventory_applyrecord/index.vue


+ 0 - 0
src/pages/search/inventory/inventory_current/index.vue


+ 0 - 0
src/pages/search/outaccount_status/outaccount_status_status/index.vue


+ 2 - 0
src/services/bus/login.ts

@@ -52,6 +52,8 @@ export const login = async (logidCode: string, password: string, byteArr: Uint8A
  * 缓存登录信息
  */
 export function setLoginData(loginData: LoginResponse) {
+    console.log('loginData', loginData);
+
     sessionStorageUtil.setItem('loginData', loginData);
 }
 

+ 2 - 0
src/services/request/serviceURL.ts

@@ -29,6 +29,7 @@ interface URL {
     iOS: string;
     android: string;
     pcNewsUrl: string;
+    pcMangerUrl: string;
 }
 
 export let serviceURL: URL = {
@@ -52,6 +53,7 @@ export let serviceURL: URL = {
     iOS: '',
     android: '',
     pcNewsUrl: '',
+    pcMangerUrl: '',
 };
 
 /**

+ 5 - 4
src/views/platinum/platinum_capital_flow/platinum_capital_flow_tab/index.vue

@@ -1,13 +1,12 @@
 <template>
   <!-- 资金流水: 资金流水-->
   <div class="platinum_capital_flow_tab">
-    资金流水
     <iframe :src="url"></iframe>
   </div>
 </template>
 
 <script lang="ts">
-import { defineComponent } from 'vue';
+import { defineComponent, ref } from 'vue';
 import { initData } from '@/common/methods';
 import { getToken } from '@/services/bus/token';
 import { serviceURL } from '@/services/request/serviceURL';
@@ -17,8 +16,10 @@ export default defineComponent({
     components: {},
     setup() {
         const token = getToken();
-        const url = 'http://192.168.31.171:5035/pcmanage/';
-        initData(() => {});
+        const url = ref<string>('');
+        initData(() => {
+            url.value = `${serviceURL.pcMangerUrl}?token=${token}`;
+        });
         return { url };
     },
 });

+ 1 - 0
src/views/platinum/platinum_pick_query/list/tab/index.vue

@@ -47,6 +47,7 @@
     </contextMenu>
     <ControlModal :selectedRow="selectedRow"
                   @refresh="getData" />
+    <component :is="componentId"></component>
   </div>
 </template>
 

+ 5 - 4
src/views/platinum/platinum_promotion_report/platinum_promotion_report_tab/index.vue

@@ -1,13 +1,12 @@
 <template>
   <!-- 推广报表: 推广报表-->
   <div class="platinum_promotion_report_tab">
-    推广报表
     <iframe :src="url"></iframe>
   </div>
 </template>
 
 <script lang="ts">
-import { defineComponent } from 'vue';
+import { defineComponent, ref } from 'vue';
 import { initData } from '@/common/methods';
 import { getToken } from '@/services/bus/token';
 import { serviceURL } from '@/services/request/serviceURL';
@@ -17,8 +16,10 @@ export default defineComponent({
     components: {},
     setup() {
         const token = getToken();
-        const url = 'http://192.168.31.171:5035/pcmanage/';
-        initData(() => {});
+        const url = ref<string>('');
+        initData(() => {
+            url.value = `${serviceURL.pcMangerUrl}?token=${token}`;
+        });
         return { url };
     },
 });