{"code":"import { __awaiter } from \"tslib\";\nimport { defineComponent } from \"vue\";\nexport default defineComponent({\n    data() {\n        return {\n            searchKey: '',\n            activeTab: '全部',\n            tabs: ['全部', '已生效', '已失效'],\n            orders: [ /* 从接口获取的数据 */]\n        };\n    },\n    computed: {\n        // 过滤后的订单列表\n        filteredOrders() {\n            return this.orders.filter(order => {\n                const matchStatus = this.activeTab === '全部' ||\n                    order.status === this.activeTab;\n                const matchSearch = order.customerName.includes(this.searchKey) ||\n                    order.phone.includes(this.searchKey);\n                return matchStatus && matchSearch;\n            });\n        }\n    },\n    methods: {\n        // 搜索处理\n        handleSearch() {\n            // 实际调用接口获取数据\n            uni.__f__('log', 'at pages/index/dingdan.uvue:78', '搜索关键词:', this.searchKey);\n        },\n        // 复制订单号\n        copyOrderNo(orderNo = null) {\n            uni.setClipboardData({\n                data: orderNo,\n                success: () => {\n                    uni.showToast({ title: '复制成功' });\n                }\n            });\n        },\n        // PDF下载\n        downloadPDF(order = null) {\n            return __awaiter(this, void 0, void 0, function* () {\n                uni.showLoading({ title: '下载中...' });\n                try {\n                    // 1. 调用下载接口\n                    const tempFilePath = (yield uni.downloadFile({\n                        url: 'https://your-api.com/download',\n                        header: new UTSJSONObject({ 'order-id': order.id })\n                    })).tempFilePath;\n                    // 2. 保存到本地\n                    yield uni.saveFile({\n                        tempFilePath,\n                        success: (res) => {\n                            uni.showToast({ title: '下载成功' });\n                            uni.__f__('log', 'at pages/index/dingdan.uvue:107', '文件路径:', res.savedFilePath);\n                        }\n                    });\n                    // 3. 打开文档（可选）\n                    uni.openDocument({\n                        filePath: tempFilePath,\n                        showMenu: true\n                    });\n                }\n                catch (err) {\n                    uni.showToast({ title: '下载失败', icon: 'none' });\n                }\n                finally {\n                    uni.hideLoading();\n                }\n            });\n        }\n    }\n});\n//# sourceMappingURL=C:/Users/lj/Desktop/121/contract-front/111/pages/index/dingdan.uvue?vue&type=script&lang.uts.js.map","references":[],"uniExtApis":["uni.__f__","uni.setClipboardData","uni.showToast","uni.showLoading","uni.downloadFile","uni.saveFile","uni.openDocument","uni.hideLoading"],"map":"{\"version\":3,\"file\":\"dingdan.uvue?vue&type=script&lang.uts.js\",\"sourceRoot\":\"\",\"sources\":[\"dingdan.uvue?vue&type=script&lang.uts\"],\"names\":[],\"mappings\":\";;AACA,+BAAe;IACb,IAAI;QACF,OAAO;YACL,SAAS,EAAE,EAAE;YACb,SAAS,EAAE,IAAI;YACf,IAAI,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,KAAK,CAAC;YAC1B,MAAM,EAAE,EAAC,cAAc,CAAC;SACzB,CAAA;IACH,CAAC;IACD,QAAQ,EAAE;QACR,WAAW;QACX,cAAc;YACZ,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK;gBAC7B,MAAM,WAAW,GAAG,IAAI,CAAC,SAAS,KAAK,IAAI;oBACzC,KAAK,CAAC,MAAM,KAAK,IAAI,CAAC,SAAS,CAAA;gBACjC,MAAM,WAAW,GAAG,KAAK,CAAC,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC;oBAC7D,KAAK,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC,CAAA;gBACtC,OAAO,WAAW,IAAI,WAAW,CAAA;YACnC,CAAC,CAAC,CAAA;QACJ,CAAC;KACF;IACD,OAAO,EAAE;QACP,OAAO;QACP,YAAY;YACV,aAAa;YACb,GAAG,CAAC,KAAK,CAAC,KAAK,EAAC,gCAAgC,EAAC,QAAQ,EAAE,IAAI,CAAC,SAAS,CAAC,CAAA;QAC5E,CAAC;QAED,QAAQ;QACR,WAAW,CAAC,OAAO,OAAA;YACjB,GAAG,CAAC,gBAAgB,CAAC;gBACnB,IAAI,EAAE,OAAO;gBACb,OAAO,EAAE;oBACP,GAAG,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAA;gBAClC,CAAC;aACF,CAAC,CAAA;QACJ,CAAC;QAED,QAA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