Commit 7a9f4368a4b432e6e18377c83a4895d6831116e2

Authored by “wangming”
1 parent 544fd30b

feat: 增强LqKdKdjlbService以支持开单记录的品项明细查询

- 在LqKdKdjlbService中添加逻辑以批量查询开单记录的品项明细
- 为每个开单记录分配对应的品项明细,确保数据完整性
- 更新LqKdKdjlbListOutput DTO以包含品项明细列表
- 优化前端Vue组件以展示新增的品项明细信息
antis-ncc-admin/src/views/lqKdKdjlb/index.vue
1 1 <template>
2   - <div class="NCC-common-layout">
3   - <div class="NCC-common-layout-center">
4   - <el-row class="NCC-common-search-box" :gutter="16">
5   - <el-form @submit.native.prevent>
6   - <!-- <el-col :span="6">
  2 + <div class="NCC-common-layout">
  3 + <div class="NCC-common-layout-center">
  4 + <el-row class="NCC-common-search-box" :gutter="16">
  5 + <el-form @submit.native.prevent>
  6 + <!-- <el-col :span="6">
7 7 <el-form-item label="开单会员">
8 8 <el-select v-model="query.kdhy" placeholder="开单会员" clearable >
9 9 <el-option v-for="(item, index) in kdhyOptions" :key="index" :label="item.fullName" :value="item.id" />
10 10 </el-select>
11 11 </el-form-item>
12 12 </el-col> -->
13   - <el-col :span="6">
14   - <el-form-item label="开单日期">
15   - <el-date-picker v-model="query.kdrq" type="daterange" value-format="timestamp" format="yyyy-MM-dd" start-placeholder="开始日期" end-placeholder="结束日期">
16   - </el-date-picker>
17   - </el-form-item>
18   - </el-col>
19   - <el-col :span="6">
20   - <el-form-item label="开单会员">
21   - <el-input v-model="query.kdhyc" placeholder="开单会员" clearable />
22   - </el-form-item>
23   - </el-col>
24   - <el-col :span="6">
25   - <el-form-item label="会员手机号">
26   - <el-input v-model="query.kdhysjh" placeholder="会员手机号" clearable />
27   - </el-form-item>
28   - </el-col>
29   -
30   - <template v-if="showAll">
31   -
32   - <el-col :span="6">
33   - <el-form-item label="单据门店">
34   - <el-select v-model="query.djmd" placeholder="单据门店" clearable >
35   - <el-option v-for="(item, index) in djmdOptions" :key="index" :label="item.fullName" :value="item.id" />
36   - </el-select>
37   - </el-form-item>
38   - </el-col>
39   - <el-col :span="6">
40   - <el-form-item label="合作机构">
41   - <el-select v-model="query.hgjg" placeholder="合作机构" clearable >
42   - <el-option v-for="(item, index) in hgjgOptions" :key="index" :label="item.fullName" :value="item.id" />
43   - </el-select>
44   - </el-form-item>
45   - </el-col>
46   - <el-col :span="6">
47   - <el-form-item label="整单业绩">
48   - <el-input v-model="query.zdyj" placeholder="整单业绩" clearable />
49   - </el-form-item>
50   - </el-col>
51   - <el-col :span="6">
52   - <el-form-item label="实付业绩">
53   - <el-input v-model="query.sfyj" placeholder="实付业绩" clearable />
54   - </el-form-item>
55   - </el-col>
56   - <el-col :span="6">
57   - <el-form-item label="欠款">
58   - <el-input v-model="query.qk" placeholder="欠款" clearable />
59   - </el-form-item>
60   - </el-col>
61   - <el-col :span="6">
62   - <el-form-item label="付款方式">
63   - <el-select v-model="query.fkfs" placeholder="付款方式" clearable >
64   - <el-option v-for="(item, index) in fkfsOptions" :key="index" :label="item.fullName" :value="item.id" />
65   - </el-select>
66   - </el-form-item>
67   - </el-col>
68   - <el-col :span="6">
69   - <el-form-item label="付款医院">
70   - <el-select v-model="query.fkyy" placeholder="付款医院" clearable >
71   - <el-option v-for="(item, index) in fkyyOptions" :key="index" :label="item.fullName" :value="item.id" />
72   - </el-select>
73   - </el-form-item>
74   - </el-col>
  13 + <el-col :span="6">
  14 + <el-form-item label="开单日期">
  15 + <el-date-picker v-model="query.kdrq" type="daterange" value-format="timestamp" format="yyyy-MM-dd"
  16 + start-placeholder="开始日期" end-placeholder="结束日期">
  17 + </el-date-picker>
  18 + </el-form-item>
  19 + </el-col>
  20 + <el-col :span="6">
  21 + <el-form-item label="开单会员">
  22 + <el-input v-model="query.kdhyc" placeholder="开单会员" clearable />
  23 + </el-form-item>
  24 + </el-col>
  25 + <el-col :span="6">
  26 + <el-form-item label="会员手机号">
  27 + <el-input v-model="query.kdhysjh" placeholder="会员手机号" clearable />
  28 + </el-form-item>
  29 + </el-col>
75 30  
76   - <el-col :span="6">
77   - <el-form-item label="是否首开订单">
78   - <el-select v-model="query.sfskdd" placeholder="是否首开订单" >
79   - <el-option v-for="(item, index) in sfskddOptions" :key="index" :label="item.fullName" :value="item.id" />
80   - </el-select>
81   - </el-form-item>
82   - </el-col>
  31 + <template v-if="showAll">
83 32  
  33 + <el-col :span="6">
  34 + <el-form-item label="单据门店">
  35 + <el-select v-model="query.djmd" placeholder="单据门店" clearable>
  36 + <el-option v-for="(item, index) in djmdOptions" :key="index" :label="item.fullName"
  37 + :value="item.id" />
  38 + </el-select>
  39 + </el-form-item>
  40 + </el-col>
  41 + <el-col :span="6">
  42 + <el-form-item label="合作机构">
  43 + <el-select v-model="query.hgjg" placeholder="合作机构" clearable>
  44 + <el-option v-for="(item, index) in hgjgOptions" :key="index" :label="item.fullName"
  45 + :value="item.id" />
  46 + </el-select>
  47 + </el-form-item>
  48 + </el-col>
  49 + <el-col :span="6">
  50 + <el-form-item label="整单业绩">
  51 + <el-input v-model="query.zdyj" placeholder="整单业绩" clearable />
  52 + </el-form-item>
  53 + </el-col>
  54 + <el-col :span="6">
  55 + <el-form-item label="实付业绩">
  56 + <el-input v-model="query.sfyj" placeholder="实付业绩" clearable />
  57 + </el-form-item>
  58 + </el-col>
  59 + <el-col :span="6">
  60 + <el-form-item label="欠款">
  61 + <el-input v-model="query.qk" placeholder="欠款" clearable />
  62 + </el-form-item>
  63 + </el-col>
  64 + <el-col :span="6">
  65 + <el-form-item label="付款方式">
  66 + <el-select v-model="query.fkfs" placeholder="付款方式" clearable>
  67 + <el-option v-for="(item, index) in fkfsOptions" :key="index" :label="item.fullName"
  68 + :value="item.id" />
  69 + </el-select>
  70 + </el-form-item>
  71 + </el-col>
  72 + <el-col :span="6">
  73 + <el-form-item label="付款医院">
  74 + <el-select v-model="query.fkyy" placeholder="付款医院" clearable>
  75 + <el-option v-for="(item, index) in fkyyOptions" :key="index" :label="item.fullName"
  76 + :value="item.id" />
  77 + </el-select>
  78 + </el-form-item>
  79 + </el-col>
84 80  
85   - </template>
86   - <el-col :span="6">
87   - <el-form-item>
88   - <el-button type="primary" icon="el-icon-search" @click="search()">查询</el-button>
89   - <el-button icon="el-icon-refresh-right" @click="reset()">重置</el-button>
90   - <el-button type="text" icon="el-icon-arrow-down" @click="showAll=true" v-if="!showAll">展开</el-button>
91   - <el-button type="text" icon="el-icon-arrow-up" @click="showAll=false" v-else>收起</el-button>
92   - </el-form-item>
93   - </el-col>
94   - </el-form>
95   - </el-row>
96   - <div class="NCC-common-layout-main NCC-flex-main">
97   - <div class="NCC-common-head">
98   - <div>
99   - <el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">新增</el-button>
100   - <el-button type="success" icon="el-icon-user" @click="openMemberCreateDialog()">建档</el-button>
101   - <el-button type="text" icon="el-icon-download" @click="exportData()">导出</el-button>
102   - <el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()">批量删除</el-button>
103   - </div>
104   - <div class="NCC-common-head-right">
105   - <el-tooltip effect="dark" content="刷新" placement="top">
106   - <el-link icon="icon-ym icon-ym-Refresh NCC-common-head-icon" :underline="false" @click="reset()" />
107   - </el-tooltip>
108   - <screenfull isContainer />
109   - </div>
110   - </div>
111   - <NCC-table
112   - v-loading="listLoading"
113   - :data="list"
114   - has-c
115   - @selection-change="handleSelectionChange"
116   - :header-cell-style="{ background: '#f5f7fa', color: '#606266' }"
117   - >
118   - <!-- 开单编号 -->
119   - <el-table-column label="开单编号" width="180" align="center" v-if="isshow">
120   - <template slot-scope="scope">
121   - <div class="order-info">
122   - <i class="el-icon-document order-icon"></i>
123   - <span class="text-nowrap">{{ scope.row.id || '无' }}</span>
124   - </div>
125   - </template>
126   - </el-table-column>
127   -
128   - <!-- 开单会员 -->
129   - <!-- <el-table-column label="开单会员" width="100" align="center">
  81 + <el-col :span="6">
  82 + <el-form-item label="是否首开订单">
  83 + <el-select v-model="query.sfskdd" placeholder="是否首开订单">
  84 + <el-option v-for="(item, index) in sfskddOptions" :key="index" :label="item.fullName"
  85 + :value="item.id" />
  86 + </el-select>
  87 + </el-form-item>
  88 + </el-col>
  89 +
  90 +
  91 + </template>
  92 + <el-col :span="6">
  93 + <el-form-item>
  94 + <el-button type="primary" icon="el-icon-search" @click="search()">查询</el-button>
  95 + <el-button icon="el-icon-refresh-right" @click="reset()">重置</el-button>
  96 + <el-button type="text" icon="el-icon-arrow-down" @click="showAll = true" v-if="!showAll">展开</el-button>
  97 + <el-button type="text" icon="el-icon-arrow-up" @click="showAll = false" v-else>收起</el-button>
  98 + </el-form-item>
  99 + </el-col>
  100 + </el-form>
  101 + </el-row>
  102 + <div class="NCC-common-layout-main NCC-flex-main">
  103 + <div class="NCC-common-head">
  104 + <div>
  105 + <el-button type="primary" icon="el-icon-plus" @click="addOrUpdateHandle()">新增</el-button>
  106 + <el-button type="success" icon="el-icon-user" @click="openMemberCreateDialog()">建档</el-button>
  107 + <el-button type="text" icon="el-icon-download" @click="exportData()">导出</el-button>
  108 + <el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()">批量删除</el-button>
  109 + </div>
  110 + <div class="NCC-common-head-right">
  111 + <el-tooltip effect="dark" content="刷新" placement="top">
  112 + <el-link icon="icon-ym icon-ym-Refresh NCC-common-head-icon" :underline="false" @click="reset()" />
  113 + </el-tooltip>
  114 + <screenfull isContainer />
  115 + </div>
  116 + </div>
  117 + <NCC-table v-loading="listLoading" :data="list" has-c @selection-change="handleSelectionChange"
  118 + :header-cell-style="{ background: '#f5f7fa', color: '#606266' }">
  119 + <!-- 开单编号 -->
  120 + <el-table-column label="开单编号" width="180" align="center" v-if="isshow">
  121 + <template slot-scope="scope">
  122 + <div class="order-info">
  123 + <i class="el-icon-document order-icon"></i>
  124 + <span class="text-nowrap">{{ scope.row.id || '无' }}</span>
  125 + </div>
  126 + </template>
  127 + </el-table-column>
  128 +
  129 + <!-- 开单会员 -->
  130 + <!-- <el-table-column label="开单会员" width="100" align="center">
130 131 <template slot-scope="scope">
131 132 <div class="member-info">
132 133 <i class="el-icon-user member-icon"></i>
... ... @@ -134,240 +135,240 @@
134 135 </div>
135 136 </template>
136 137 </el-table-column> -->
137   -
138   - <!-- 开单会员名称 -->
139   - <el-table-column label="开单会员" width="100" align="center">
140   - <template slot-scope="scope">
141   - <div class="member-name">
142   - <i class="el-icon-user-solid member-name-icon"></i>
143   - <span class="text-nowrap">{{ scope.row.kdhyc || '无' }}</span>
144   - </div>
145   - </template>
146   - </el-table-column>
147   -
148   - <!-- 会员手机号 -->
149   - <el-table-column label="会员手机号" width="120" align="center">
150   - <template slot-scope="scope">
151   - <div class="phone-info">
152   - <i class="el-icon-phone phone-icon"></i>
153   - <span class="text-nowrap">{{ scope.row.kdhysjh || '无' }}</span>
154   - </div>
155   - </template>
156   - </el-table-column>
157   -
158   - <!-- 单据门店 -->
159   - <el-table-column label="单据门店" width="120" align="center">
160   - <template slot-scope="scope">
161   - <div class="store-info">
162   - <i class="el-icon-office-building store-icon"></i>
163   - <span class="text-nowrap">{{ scope.row.djmd | dynamicText(djmdOptions) || '无' }}</span>
164   - </div>
165   - </template>
166   - </el-table-column>
167   -
168   - <!-- 金三角 -->
169   - <el-table-column label="金三角" width="120" align="center">
170   - <template slot-scope="scope">
171   - <div class="jsj-info">
172   - <i class="el-icon-star-on jsj-icon"></i>
173   - <span class="text-nowrap">{{ scope.row.jsj | dynamicText(jsjOptions) || '无' }}</span>
174   - </div>
175   - </template>
176   - </el-table-column>
177   -
178   - <!-- 开单日期 -->
179   - <el-table-column label="开单日期" width="120" align="center">
180   - <template slot-scope="scope">
181   - <div class="date-info">
182   - <i class="el-icon-date date-icon"></i>
183   - <span class="text-nowrap">{{ formatDate(scope.row.kdrq) }}</span>
184   - </div>
185   - </template>
186   - </el-table-column>
187   -
188   - <!-- 顾客类型 -->
189   - <el-table-column label="顾客类型" width="120" align="center">
190   - <template slot-scope="scope">
191   - <div class="customer-type-info">
192   - <i class="el-icon-user customer-type-icon"></i>
193   - <span class="text-nowrap">{{ scope.row.gjlx }}</span>
194   - </div>
195   - </template>
196   - </el-table-column>
197   - <!-- 整单业绩 -->
198   - <el-table-column label="整单业绩" width="120" align="center">
199   - <template slot-scope="scope">
200   - <div class="amount-info">
201   - <i class="el-icon-money amount-icon"></i>
202   - <span class="text-nowrap">{{ scope.row.zdyj || '无' }}</span>
203   - </div>
204   - </template>
205   - </el-table-column>
206   -
207   - <!-- 实付业绩 -->
208   - <el-table-column label="实付业绩" width="120" align="center">
209   - <template slot-scope="scope">
210   - <div class="paid-amount-info">
211   - <i class="el-icon-coin paid-amount-icon"></i>
212   - <span class="text-nowrap">{{ scope.row.sfyj || '无' }}</span>
213   - </div>
214   - </template>
215   - </el-table-column>
216   -
217   - <!-- 欠款 -->
218   - <el-table-column label="欠款" width="100" align="center">
219   - <template slot-scope="scope">
220   - <div class="debt-info">
221   - <i class="el-icon-warning debt-icon"></i>
222   - <span class="text-nowrap">{{ scope.row.qk || '无' }}</span>
223   - </div>
224   - </template>
225   - </el-table-column>
226   -
227   - <!-- 储扣方式 -->
228   - <el-table-column label="储扣方式" width="120" align="center">
229   - <template slot-scope="scope">
230   - <div class="storage-info">
231   - <i class="el-icon-coin storage-icon"></i>
232   - <span class="text-nowrap">{{ scope.row.ckfs | dynamicText(ckfsOptions) || '无' }}</span>
233   - </div>
234   - </template>
235   - </el-table-column>
236   -
237   - <!-- 储扣明细 -->
238   - <el-table-column label="储扣明细" width="120" align="center" v-if="isshow">
239   - <template slot-scope="scope">
240   - <div class="storage-detail-info">
241   - <i class="el-icon-document storage-detail-icon"></i>
242   - <span class="text-nowrap">{{ scope.row.ckmx || '无' }}</span>
243   - </div>
244   - </template>
245   - </el-table-column>
246   -
247   - <!-- 付款方式 -->
248   - <el-table-column label="付款方式" width="120" align="center">
249   - <template slot-scope="scope">
250   - <div class="payment-info">
251   - <i class="el-icon-credit-card payment-icon"></i>
252   - <span class="text-nowrap">{{ scope.row.fkfs | dynamicText(fkfsOptions) || '无' }}</span>
253   - </div>
254   - </template>
255   - </el-table-column>
256   -
257   - <!-- 付款医院 -->
258   - <el-table-column label="付款医院" width="120" align="center">
259   - <template slot-scope="scope">
260   - <div class="hospital-info">
261   - <i class="el-icon-office-building hospital-icon"></i>
262   - <span class="text-nowrap">{{ scope.row.fkyy | dynamicText(fkyyOptions) || '无' }}</span>
263   - </div>
264   - </template>
265   - </el-table-column>
266   - <!-- 合作机构 -->
267   - <el-table-column label="合作机构" width="120" align="center">
268   - <template slot-scope="scope">
269   - <div class="cooperation-info">
270   - <i class="el-icon-office-building cooperation-icon"></i>
271   - <span class="text-nowrap">{{ scope.row.hgjg | dynamicText(hgjgOptions) || '无' }}</span>
272   - </div>
273   - </template>
274   - </el-table-column>
275   -
276   - <!-- 付款判断 -->
277   - <el-table-column label="付款判断" width="120" align="center" v-if="isshow">
278   - <template slot-scope="scope">
279   - <div class="payment-judge-info">
280   - <i class="el-icon-check payment-judge-icon"></i>
281   - <span class="text-nowrap">{{ scope.row.fkpd || '无' }}</span>
282   - </div>
283   - </template>
284   - </el-table-column>
285   -
286   - <!-- 客户来源 -->
287   - <el-table-column label="客户来源" width="120" align="center" v-if="isshow">
288   - <template slot-scope="scope">
289   - <div class="source-info">
290   - <i class="el-icon-connection source-icon"></i>
291   - <span class="text-nowrap">{{ scope.row.khly | dynamicText(khlyOptions) || '无' }}</span>
292   - </div>
293   - </template>
294   - </el-table-column>
295   -
296   - <!-- 推荐人 -->
297   - <el-table-column label="推荐人" width="100" align="center" v-if="isshow">
298   - <template slot-scope="scope">
299   - <div class="referrer-info">
300   - <i class="el-icon-user referrer-icon"></i>
301   - <span class="text-nowrap">{{ scope.row.tjr || '无' }}</span>
302   - </div>
303   - </template>
304   - </el-table-column>
305   -
306   - <!-- 是否首开订单 -->
307   - <el-table-column label="是否首开订单" width="140" align="center">
308   - <template slot-scope="scope">
309   - <div class="first-order-info">
310   - <i class="el-icon-star-on first-order-icon"></i>
311   - <span class="text-nowrap">{{ scope.row.sfskdd | dynamicText(sfskddOptions) || '无' }}</span>
312   - </div>
313   - </template>
314   - </el-table-column>
315   -
316   - <!-- 简介 -->
317   - <el-table-column label="简介" width="120" align="center" v-if="isshow">
318   - <template slot-scope="scope">
319   - <div class="intro-info">
320   - <i class="el-icon-document intro-icon"></i>
321   - <span class="text-nowrap">{{ scope.row.jj || '无' }}</span>
322   - </div>
323   - </template>
324   - </el-table-column>
325   -
326   - <!-- 备注 -->
327   - <el-table-column label="备注" min-width="150" show-overflow-tooltip v-if="isshow">
328   - <template slot-scope="scope">
329   - <div class="remark-info">
330   - <i class="el-icon-document remark-icon"></i>
331   - <span class="text-nowrap">{{ scope.row.bz || '无' }}</span>
332   - </div>
333   - </template>
334   - </el-table-column>
335   -
336   - <!-- 健康师业绩 -->
337   - <el-table-column label="健康师业绩" width="130" align="center" v-if="isshow">
338   - <template slot-scope="scope">
339   - <div class="jks-amount-info">
340   - <i class="el-icon-medicine-box jks-amount-icon"></i>
341   - <span class="text-nowrap">{{ scope.row.jksyj || '无' }}</span>
342   - </div>
343   - </template>
344   - </el-table-column>
345   -
346   - <!-- 科技部老师业绩 -->
347   - <el-table-column label="科技部老师业绩" width="150" align="center" v-if="isshow">
348   - <template slot-scope="scope">
349   - <div class="kjb-amount-info">
350   - <i class="el-icon-cpu kjb-amount-icon"></i>
351   - <span class="text-nowrap">{{ scope.row.kjblsyj || '无' }}</span>
352   - </div>
353   - </template>
354   - </el-table-column>
355   -
356   - <!-- 品项信息 -->
357   - <el-table-column label="品项信息" width="120" align="center" v-if="isshow">
358   - <template slot-scope="scope">
359   - <div class="product-info">
360   - <i class="el-icon-goods product-icon"></i>
361   - <span class="text-nowrap">{{ scope.row.pxxx || '无' }}</span>
362   - </div>
363   - </template>
364   - </el-table-column>
365   -
366   - <!-- 操作 -->
367   - <el-table-column label="操作" width="160" align="left" fixed="right">
368   - <template slot-scope="scope">
369   - <div class="action-buttons">
370   - <!-- <el-button
  138 +
  139 + <!-- 开单会员名称 -->
  140 + <el-table-column label="开单会员" width="100" align="center">
  141 + <template slot-scope="scope">
  142 + <div class="member-name">
  143 + <i class="el-icon-user-solid member-name-icon"></i>
  144 + <span class="text-nowrap">{{ scope.row.kdhyc || '无' }}</span>
  145 + </div>
  146 + </template>
  147 + </el-table-column>
  148 +
  149 + <!-- 会员手机号 -->
  150 + <el-table-column label="会员手机号" width="120" align="center">
  151 + <template slot-scope="scope">
  152 + <div class="phone-info">
  153 + <i class="el-icon-phone phone-icon"></i>
  154 + <span class="text-nowrap">{{ scope.row.kdhysjh || '无' }}</span>
  155 + </div>
  156 + </template>
  157 + </el-table-column>
  158 +
  159 + <!-- 单据门店 -->
  160 + <el-table-column label="单据门店" width="120" align="center">
  161 + <template slot-scope="scope">
  162 + <div class="store-info">
  163 + <i class="el-icon-office-building store-icon"></i>
  164 + <span class="text-nowrap">{{ scope.row.djmd | dynamicText(djmdOptions) || '无' }}</span>
  165 + </div>
  166 + </template>
  167 + </el-table-column>
  168 +
  169 + <!-- 金三角 -->
  170 + <el-table-column label="金三角" width="120" align="center">
  171 + <template slot-scope="scope">
  172 + <div class="jsj-info">
  173 + <i class="el-icon-star-on jsj-icon"></i>
  174 + <span class="text-nowrap">{{ scope.row.jsj | dynamicText(jsjOptions) || '无' }}</span>
  175 + </div>
  176 + </template>
  177 + </el-table-column>
  178 +
  179 + <!-- 开单日期 -->
  180 + <el-table-column label="开单日期" width="120" align="center">
  181 + <template slot-scope="scope">
  182 + <div class="date-info">
  183 + <i class="el-icon-date date-icon"></i>
  184 + <span class="text-nowrap">{{ formatDate(scope.row.kdrq) }}</span>
  185 + </div>
  186 + </template>
  187 + </el-table-column>
  188 +
  189 + <!-- 顾客类型 -->
  190 + <el-table-column label="顾客类型" width="120" align="center">
  191 + <template slot-scope="scope">
  192 + <div class="customer-type-info">
  193 + <i class="el-icon-user customer-type-icon"></i>
  194 + <span class="text-nowrap">{{ scope.row.gjlx }}</span>
  195 + </div>
  196 + </template>
  197 + </el-table-column>
  198 + <!-- 整单业绩 -->
  199 + <el-table-column label="整单业绩" width="120" align="center">
  200 + <template slot-scope="scope">
  201 + <div class="amount-info">
  202 + <i class="el-icon-money amount-icon"></i>
  203 + <span class="text-nowrap">{{ scope.row.zdyj || '无' }}</span>
  204 + </div>
  205 + </template>
  206 + </el-table-column>
  207 +
  208 + <!-- 实付业绩 -->
  209 + <el-table-column label="实付业绩" width="120" align="center">
  210 + <template slot-scope="scope">
  211 + <div class="paid-amount-info">
  212 + <i class="el-icon-coin paid-amount-icon"></i>
  213 + <span class="text-nowrap">{{ scope.row.sfyj || '无' }}</span>
  214 + </div>
  215 + </template>
  216 + </el-table-column>
  217 +
  218 + <!-- 欠款 -->
  219 + <el-table-column label="欠款" width="100" align="center">
  220 + <template slot-scope="scope">
  221 + <div class="debt-info">
  222 + <i class="el-icon-warning debt-icon"></i>
  223 + <span class="text-nowrap">{{ scope.row.qk || '无' }}</span>
  224 + </div>
  225 + </template>
  226 + </el-table-column>
  227 +
  228 + <!-- 储扣方式 -->
  229 + <el-table-column label="储扣方式" width="120" align="center">
  230 + <template slot-scope="scope">
  231 + <div class="storage-info">
  232 + <i class="el-icon-coin storage-icon"></i>
  233 + <span class="text-nowrap">{{ scope.row.ckfs | dynamicText(ckfsOptions) || '无' }}</span>
  234 + </div>
  235 + </template>
  236 + </el-table-column>
  237 +
  238 + <!-- 储扣明细 -->
  239 + <el-table-column label="储扣明细" width="120" align="center" v-if="isshow">
  240 + <template slot-scope="scope">
  241 + <div class="storage-detail-info">
  242 + <i class="el-icon-document storage-detail-icon"></i>
  243 + <span class="text-nowrap">{{ scope.row.ckmx || '无' }}</span>
  244 + </div>
  245 + </template>
  246 + </el-table-column>
  247 +
  248 + <!-- 付款方式 -->
  249 + <el-table-column label="付款方式" width="120" align="center">
  250 + <template slot-scope="scope">
  251 + <div class="payment-info">
  252 + <i class="el-icon-credit-card payment-icon"></i>
  253 + <span class="text-nowrap">{{ scope.row.fkfs | dynamicText(fkfsOptions) || '无' }}</span>
  254 + </div>
  255 + </template>
  256 + </el-table-column>
  257 +
  258 + <!-- 付款医院 -->
  259 + <el-table-column label="付款医院" width="120" align="center">
  260 + <template slot-scope="scope">
  261 + <div class="hospital-info">
  262 + <i class="el-icon-office-building hospital-icon"></i>
  263 + <span class="text-nowrap">{{ scope.row.fkyy | dynamicText(fkyyOptions) || '无' }}</span>
  264 + </div>
  265 + </template>
  266 + </el-table-column>
  267 + <!-- 合作机构 -->
  268 + <el-table-column label="合作机构" width="120" align="center">
  269 + <template slot-scope="scope">
  270 + <div class="cooperation-info">
  271 + <i class="el-icon-office-building cooperation-icon"></i>
  272 + <span class="text-nowrap">{{ scope.row.hgjg | dynamicText(hgjgOptions) || '无' }}</span>
  273 + </div>
  274 + </template>
  275 + </el-table-column>
  276 +
  277 + <!-- 付款判断 -->
  278 + <el-table-column label="付款判断" width="120" align="center" v-if="isshow">
  279 + <template slot-scope="scope">
  280 + <div class="payment-judge-info">
  281 + <i class="el-icon-check payment-judge-icon"></i>
  282 + <span class="text-nowrap">{{ scope.row.fkpd || '无' }}</span>
  283 + </div>
  284 + </template>
  285 + </el-table-column>
  286 +
  287 + <!-- 客户来源 -->
  288 + <el-table-column label="客户来源" width="120" align="center" v-if="isshow">
  289 + <template slot-scope="scope">
  290 + <div class="source-info">
  291 + <i class="el-icon-connection source-icon"></i>
  292 + <span class="text-nowrap">{{ scope.row.khly | dynamicText(khlyOptions) || '无' }}</span>
  293 + </div>
  294 + </template>
  295 + </el-table-column>
  296 +
  297 + <!-- 推荐人 -->
  298 + <el-table-column label="推荐人" width="100" align="center" v-if="isshow">
  299 + <template slot-scope="scope">
  300 + <div class="referrer-info">
  301 + <i class="el-icon-user referrer-icon"></i>
  302 + <span class="text-nowrap">{{ scope.row.tjr || '无' }}</span>
  303 + </div>
  304 + </template>
  305 + </el-table-column>
  306 +
  307 + <!-- 是否首开订单 -->
  308 + <el-table-column label="是否首开订单" width="140" align="center">
  309 + <template slot-scope="scope">
  310 + <div class="first-order-info">
  311 + <i class="el-icon-star-on first-order-icon"></i>
  312 + <span class="text-nowrap">{{ scope.row.sfskdd | dynamicText(sfskddOptions) || '无' }}</span>
  313 + </div>
  314 + </template>
  315 + </el-table-column>
  316 +
  317 + <!-- 简介 -->
  318 + <el-table-column label="简介" width="120" align="center" v-if="isshow">
  319 + <template slot-scope="scope">
  320 + <div class="intro-info">
  321 + <i class="el-icon-document intro-icon"></i>
  322 + <span class="text-nowrap">{{ scope.row.jj || '无' }}</span>
  323 + </div>
  324 + </template>
  325 + </el-table-column>
  326 +
  327 + <!-- 备注 -->
  328 + <el-table-column label="备注" show-overflow-tooltip>
  329 + <template slot-scope="scope">
  330 + <div class="remark-info">
  331 + <i class="el-icon-document remark-icon"></i>
  332 + <span class="text-nowrap">{{ scope.row.bz || '无' }}</span>
  333 + </div>
  334 + </template>
  335 + </el-table-column>
  336 +
  337 + <!-- 健康师业绩 -->
  338 + <el-table-column label="健康师业绩" width="130" align="center" v-if="isshow">
  339 + <template slot-scope="scope">
  340 + <div class="jks-amount-info">
  341 + <i class="el-icon-medicine-box jks-amount-icon"></i>
  342 + <span class="text-nowrap">{{ scope.row.jksyj || '无' }}</span>
  343 + </div>
  344 + </template>
  345 + </el-table-column>
  346 +
  347 + <!-- 科技部老师业绩 -->
  348 + <el-table-column label="科技部老师业绩" width="150" align="center" v-if="isshow">
  349 + <template slot-scope="scope">
  350 + <div class="kjb-amount-info">
  351 + <i class="el-icon-cpu kjb-amount-icon"></i>
  352 + <span class="text-nowrap">{{ scope.row.kjblsyj || '无' }}</span>
  353 + </div>
  354 + </template>
  355 + </el-table-column>
  356 +
  357 + <!-- 品项信息 -->
  358 + <el-table-column label="品项信息" width="120" align="center" v-if="isshow">
  359 + <template slot-scope="scope">
  360 + <div class="product-info">
  361 + <i class="el-icon-goods product-icon"></i>
  362 + <span class="text-nowrap">{{ scope.row.pxxx || '无' }}</span>
  363 + </div>
  364 + </template>
  365 + </el-table-column>
  366 +
  367 + <!-- 操作 -->
  368 + <el-table-column label="操作" width="160" align="left" fixed="right">
  369 + <template slot-scope="scope">
  370 + <div class="action-buttons">
  371 + <!-- <el-button
371 372 type="text"
372 373 icon="el-icon-edit"
373 374 @click="addOrUpdateHandle(scope.row.id)"
... ... @@ -375,14 +376,10 @@
375 376 >
376 377 编辑
377 378 </el-button> -->
378   - <el-button
379   - type="text"
380   - @click="detailHandle(scope.row.id)"
381   - class="edit-btn"
382   - >
383   - 详情
384   - </el-button>
385   - <!-- <el-button
  379 + <el-button type="text" @click="detailHandle(scope.row.id)" class="edit-btn">
  380 + 详情
  381 + </el-button>
  382 + <!-- <el-button
386 383 type="text"
387 384 icon="el-icon-delete"
388 385 @click="handleDel(scope.row.id)"
... ... @@ -390,304 +387,302 @@
390 387 >
391 388 删除
392 389 </el-button> -->
393   - </div>
394   - </template>
395   - </el-table-column>
396   - </NCC-table>
397   - <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize" @pagination="initData" />
398   - </div>
399   - </div>
400   - <NCC-Form v-if="formVisible" ref="NCCForm" @refresh="refresh" />
401   - <ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
  390 + </div>
  391 + </template>
  392 + </el-table-column>
  393 + </NCC-table>
  394 + <pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
  395 + @pagination="initData" />
  396 + </div>
  397 + </div>
  398 + <NCC-Form v-if="formVisible" ref="NCCForm" @refresh="refresh" />
  399 + <ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
402 400 <LqKdKdjlbDetail ref="detailDialog" />
403   - <MemberCreateDialog
404   - :visible.sync="memberCreateVisible"
405   - @success="handleMemberCreateSuccess"
406   - />
407   - </div>
  401 + <MemberCreateDialog :visible.sync="memberCreateVisible" @success="handleMemberCreateSuccess" />
  402 + </div>
408 403 </template>
409 404 <script>
410   - import request from '@/utils/request'
411   - import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
412   - import NCCForm from './Form'
413   - import ExportBox from './ExportBox'
414   - import LqKdKdjlbDetail from './detail'
415   - import MemberCreateDialog from './MemberCreateDialog'
416   - import { previewDataInterface } from '@/api/systemData/dataInterface'
417   - export default {
418   - components: { NCCForm, ExportBox, MemberCreateDialog, LqKdKdjlbDetail },
419   - data() {
420   - return {
421   - isshow: false,
422   - showAll: false,
423   - query: {
424   - id:undefined,
425   - kdhy:undefined,
426   - kdhyc:undefined,
427   - kdhysjh:undefined,
428   - djmd:undefined,
429   - jsj:undefined,
430   - kdrq:undefined,
431   - gjlx:undefined,
432   - hgjg:undefined,
433   - zdyj:undefined,
434   - sfyj:undefined,
435   - qk:undefined,
436   - ckfs:undefined,
437   - ckmx:undefined,
438   - fkfs:undefined,
439   - fkyy:undefined,
440   - fkpd:undefined,
441   - khly:undefined,
442   - tjr:undefined,
443   - sfskdd:undefined,
444   - jj:undefined,
445   - bz:undefined,
446   - jksyj:undefined,
447   - kjblsyj:undefined,
448   - pxxx:undefined,
449   - },
450   - list: [],
451   - listLoading: true,
452   - multipleSelection: [], total: 0,
453   - listQuery: {
454   - currentPage: 1,
455   - pageSize: 20,
456   - sort: "desc",
457   - sidx: "",
458   - },
459   - formVisible: false,
460   - exportBoxVisible: false,
461   - memberCreateVisible: false,
462   - columnList: [
463   - { prop: 'id', label: '开单编号' },
464   - { prop: 'kdhy', label: '开单会员' },
465   - { prop: 'kdhyc', label: '开单会员名称' },
466   - { prop: 'kdhysjh', label: '会员手机号' },
467   - { prop: 'djmd', label: '单据门店' },
468   - { prop: 'jsj', label: '金三角' },
469   - { prop: 'kdrq', label: '开单日期' },
470   - { prop: 'gjlx', label: '顾客类型' },
471   - { prop: 'hgjg', label: '合作机构' },
472   - { prop: 'zdyj', label: '整单业绩' },
473   - { prop: 'sfyj', label: '实付业绩' },
474   - { prop: 'qk', label: '欠款' },
475   - { prop: 'ckfs', label: '储扣方式' },
476   - { prop: 'ckmx', label: '储扣明细' },
477   - { prop: 'fkfs', label: '付款方式' },
478   - { prop: 'fkyy', label: '付款医院' },
479   - { prop: 'fkpd', label: '付款判断' },
480   - { prop: 'khly', label: '客户来源' },
481   - { prop: 'tjr', label: '推荐人' },
482   - { prop: 'sfskdd', label: '是否首开订单' },
483   - { prop: 'jj', label: '简介' },
484   - { prop: 'bz', label: '备注' },
485   - { prop: 'jksyj', label: '健康师业绩' },
486   - { prop: 'kjblsyj', label: '科技部老师业绩' },
487   - { prop: 'pxxx', label: '品项信息' },
488   - ],
489   - kdhyOptions : [],
490   - djmdOptions : [],
491   - jsjOptions : [],
492   - hgjgOptions : [],
493   - ckfsOptions:[{"fullName":"储值卡","id":"储值卡"},{"fullName":"扣项","id":"扣项"},{"fullName":"套餐","id":"套餐"}],
494   - fkfsOptions:[{"fullName":"现金","id":"现金"},{"fullName":"微信","id":"微信"},{"fullName":"支付宝","id":"支付宝"},{"fullName":"银行卡","id":"银行卡"},{"fullName":"合作","id":"合作"},{"fullName":"医院","id":"医院"}],
495   - fkyyOptions : [],
496   - khlyOptions:[{"fullName":"自然到店","id":"自然到店"},{"fullName":"会员推广","id":"会员推广"},{"fullName":"网络推广","id":"网络推广"}],
497   - sfskddOptions:[{"fullName":"是","id":"是"},{"fullName":"否","id":"否"}],
498   - }
499   - },
500   - computed: {},
501   - created() {
502   - this.initData()
503   - // this.getkdhyOptions();
504   - this.getdjmdOptions();
505   - this.getjsjOptions();
506   - this.gethgjgOptions();
507   - this.getfkyyOptions();
508   - },
509   - methods: {
510   - detailHandle(id){
511   - this.$refs.detailDialog.init(id)
512   - },
513   - getkdhyOptions(){
514   - previewDataInterface('730998109110273285').then(res => {
515   - this.kdhyOptions = res.data
516   - });
517   - },
518   - getdjmdOptions(){
519   - previewDataInterface('730960205902251269').then(res => {
520   - this.djmdOptions = res.data
521   - });
522   - },
523   - getjsjOptions(){
524   - previewDataInterface('733894897408410885').then(res => {
525   - this.jsjOptions = res.data
526   - });
527   - },
528   - gethgjgOptions(){
529   - previewDataInterface('733896629660157189').then(res => {
530   - this.hgjgOptions = res.data
531   - });
532   - },
533   - getfkyyOptions(){
534   - previewDataInterface('733898797075137797').then(res => {
535   - this.fkyyOptions = res.data
536   - });
537   - },
538   - initData() {
539   - this.listLoading = true;
540   - let _query = {
541   - ...this.listQuery,
542   - ...this.query
543   - };
544   - let query = {}
545   - for (let key in _query) {
546   - if (Array.isArray(_query[key])) {
547   - query[key] = _query[key].join()
548   - } else {
549   - query[key] = _query[key]
550   - }
551   - }
552   - request({
553   - url: `/api/Extend/LqKdKdjlb`,
554   - method: 'GET',
555   - data: query
556   - }).then(res => {
557   - this.list = res.data.list
558   - this.total = res.data.pagination.total
559   - this.listLoading = false
560   - })
561   - },
562   - handleDel(id) {
563   - this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
564   - type: 'warning'
565   - }).then(() => {
566   - request({
567   - url: `/api/Extend/LqKdKdjlb/${id}`,
568   - method: 'DELETE'
569   - }).then(res => {
570   - this.$message({
571   - type: 'success',
572   - message: res.msg,
573   - onClose: () => {
574   - this.initData()
575   - }
576   - });
577   - })
578   - }).catch(() => {
579   - });
580   - },
581   - handleSelectionChange(val) {
582   - const res = val.map(item => item.id)
583   - this.multipleSelection = res
584   - },
585   - handleBatchRemoveDel() {
586   - if (!this.multipleSelection.length) {
587   - this.$message({
588   - type: 'error',
589   - message: '请选择一条数据',
590   - duration: 1500,
591   - })
592   - return
593   - }
594   - const ids = this.multipleSelection
595   - this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
596   - type: 'warning'
597   - }).then(() => {
598   - request({
599   - url: `/api/Extend/LqKdKdjlb/batchRemove`,
600   - method: 'POST',
601   - data: ids ,
602   - }).then(res => {
603   - this.$message({
604   - type: 'success',
605   - message: res.msg,
606   - onClose: () => {
607   - this.initData()
608   - }
609   - });
610   - })
611   - }).catch(() => { })
612   - },
613   - addOrUpdateHandle(id, isDetail) {
614   - this.formVisible = true
615   - this.$nextTick(() => {
616   - this.$refs.NCCForm.init(id, isDetail)
617   - })
618   - },
619   - exportData() {
620   - this.exportBoxVisible = true
621   - this.$nextTick(() => {
622   - this.$refs.ExportBox.init(this.columnList)
623   - })
624   - },
625   - download(data) {
626   - let query = { ...data, ...this.listQuery, ...this.query }
627   - request({
628   - url: `/api/Extend/LqKdKdjlb/Actions/Export`,
629   - method: 'GET',
630   - data: query
631   - }).then(res => {
632   - if (!res.data.url) return
633   - window.location.href = this.define.comUrl + res.data.url
634   - this.$refs.ExportBox.visible = false
635   - this.exportBoxVisible = false
636   - })
637   - },
638   - search() {
639   - this.listQuery = {
640   - currentPage: 1,
641   - pageSize: 20,
642   - sort: "desc",
643   - sidx: "",
644   - }
645   - this.initData()
646   - },
647   - refresh(isrRefresh) {
648   - this.formVisible = false
649   - if (isrRefresh) this.reset()
650   - },
651   - reset() {
652   - for (let key in this.query) {
653   - this.query[key] = undefined
654   - }
655   - this.listQuery = {
656   - currentPage: 1,
657   - pageSize: 20,
658   - sort: "desc",
659   - sidx: "",
660   - }
661   - this.initData()
662   - },
663   - // 格式化日期
664   - formatDate(date) {
665   - if (!date) return '无'
666   - const d = new Date(date)
667   - if (isNaN(d.getTime())) return '无'
668   - return d.toLocaleDateString('zh-CN', {
669   - year: 'numeric',
670   - month: '2-digit',
671   - day: '2-digit'
672   - })
673   - },
674   - // 打开会员建档弹窗
675   - openMemberCreateDialog() {
676   - this.memberCreateVisible = true
677   - },
678   - // 处理会员建档成功
679   - handleMemberCreateSuccess(memberData) {
680   - console.log('会员建档成功:', memberData)
681   - // 刷新会员列表
682   - this.getkdhyOptions()
683   - // 自动选择新创建的会员
684   - if (memberData && memberData.id) {
685   - this.query.kdhy = memberData.id
686   - this.$message.success('会员建档成功,已自动选择该会员')
687   - }
  405 +import request from '@/utils/request'
  406 +import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
  407 +import NCCForm from './Form'
  408 +import ExportBox from './ExportBox'
  409 +import LqKdKdjlbDetail from './detail'
  410 +import MemberCreateDialog from './MemberCreateDialog'
  411 +import { previewDataInterface } from '@/api/systemData/dataInterface'
  412 +export default {
  413 + components: { NCCForm, ExportBox, MemberCreateDialog, LqKdKdjlbDetail },
  414 + data() {
  415 + return {
  416 + isshow: false,
  417 + showAll: false,
  418 + query: {
  419 + id: undefined,
  420 + kdhy: undefined,
  421 + kdhyc: undefined,
  422 + kdhysjh: undefined,
  423 + djmd: undefined,
  424 + jsj: undefined,
  425 + kdrq: undefined,
  426 + gjlx: undefined,
  427 + hgjg: undefined,
  428 + zdyj: undefined,
  429 + sfyj: undefined,
  430 + qk: undefined,
  431 + ckfs: undefined,
  432 + ckmx: undefined,
  433 + fkfs: undefined,
  434 + fkyy: undefined,
  435 + fkpd: undefined,
  436 + khly: undefined,
  437 + tjr: undefined,
  438 + sfskdd: undefined,
  439 + jj: undefined,
  440 + bz: undefined,
  441 + jksyj: undefined,
  442 + kjblsyj: undefined,
  443 + pxxx: undefined,
  444 + },
  445 + list: [],
  446 + listLoading: true,
  447 + multipleSelection: [], total: 0,
  448 + listQuery: {
  449 + currentPage: 1,
  450 + pageSize: 20,
  451 + sort: "desc",
  452 + sidx: "",
  453 + },
  454 + formVisible: false,
  455 + exportBoxVisible: false,
  456 + memberCreateVisible: false,
  457 + columnList: [
  458 + { prop: 'id', label: '开单编号' },
  459 + { prop: 'kdhy', label: '开单会员' },
  460 + { prop: 'kdhyc', label: '开单会员名称' },
  461 + { prop: 'kdhysjh', label: '会员手机号' },
  462 + { prop: 'djmd', label: '单据门店' },
  463 + { prop: 'jsj', label: '金三角' },
  464 + { prop: 'kdrq', label: '开单日期' },
  465 + { prop: 'gjlx', label: '顾客类型' },
  466 + { prop: 'hgjg', label: '合作机构' },
  467 + { prop: 'zdyj', label: '整单业绩' },
  468 + { prop: 'sfyj', label: '实付业绩' },
  469 + { prop: 'qk', label: '欠款' },
  470 + { prop: 'ckfs', label: '储扣方式' },
  471 + { prop: 'ckmx', label: '储扣明细' },
  472 + { prop: 'fkfs', label: '付款方式' },
  473 + { prop: 'fkyy', label: '付款医院' },
  474 + { prop: 'fkpd', label: '付款判断' },
  475 + { prop: 'khly', label: '客户来源' },
  476 + { prop: 'tjr', label: '推荐人' },
  477 + { prop: 'sfskdd', label: '是否首开订单' },
  478 + { prop: 'jj', label: '简介' },
  479 + { prop: 'bz', label: '备注' },
  480 + { prop: 'jksyj', label: '健康师业绩' },
  481 + { prop: 'kjblsyj', label: '科技部老师业绩' },
  482 + { prop: 'pxxx', label: '品项信息' },
  483 + ],
  484 + kdhyOptions: [],
  485 + djmdOptions: [],
  486 + jsjOptions: [],
  487 + hgjgOptions: [],
  488 + ckfsOptions: [{ "fullName": "储值卡", "id": "储值卡" }, { "fullName": "扣项", "id": "扣项" }, { "fullName": "套餐", "id": "套餐" }],
  489 + fkfsOptions: [{ "fullName": "现金", "id": "现金" }, { "fullName": "微信", "id": "微信" }, { "fullName": "支付宝", "id": "支付宝" }, { "fullName": "银行卡", "id": "银行卡" }, { "fullName": "合作", "id": "合作" }, { "fullName": "医院", "id": "医院" }],
  490 + fkyyOptions: [],
  491 + khlyOptions: [{ "fullName": "自然到店", "id": "自然到店" }, { "fullName": "会员推广", "id": "会员推广" }, { "fullName": "网络推广", "id": "网络推广" }],
  492 + sfskddOptions: [{ "fullName": "是", "id": "是" }, { "fullName": "否", "id": "否" }],
  493 + }
  494 + },
  495 + computed: {},
  496 + created() {
  497 + this.initData()
  498 + // this.getkdhyOptions();
  499 + this.getdjmdOptions();
  500 + this.getjsjOptions();
  501 + this.gethgjgOptions();
  502 + this.getfkyyOptions();
  503 + },
  504 + methods: {
  505 + detailHandle(id) {
  506 + this.$refs.detailDialog.init(id)
  507 + },
  508 + getkdhyOptions() {
  509 + previewDataInterface('730998109110273285').then(res => {
  510 + this.kdhyOptions = res.data
  511 + });
  512 + },
  513 + getdjmdOptions() {
  514 + previewDataInterface('730960205902251269').then(res => {
  515 + this.djmdOptions = res.data
  516 + });
  517 + },
  518 + getjsjOptions() {
  519 + previewDataInterface('733894897408410885').then(res => {
  520 + this.jsjOptions = res.data
  521 + });
  522 + },
  523 + gethgjgOptions() {
  524 + previewDataInterface('733896629660157189').then(res => {
  525 + this.hgjgOptions = res.data
  526 + });
  527 + },
  528 + getfkyyOptions() {
  529 + previewDataInterface('733898797075137797').then(res => {
  530 + this.fkyyOptions = res.data
  531 + });
  532 + },
  533 + initData() {
  534 + this.listLoading = true;
  535 + let _query = {
  536 + ...this.listQuery,
  537 + ...this.query
  538 + };
  539 + let query = {}
  540 + for (let key in _query) {
  541 + if (Array.isArray(_query[key])) {
  542 + query[key] = _query[key].join()
  543 + } else {
  544 + query[key] = _query[key]
  545 + }
  546 + }
  547 + request({
  548 + url: `/api/Extend/LqKdKdjlb`,
  549 + method: 'GET',
  550 + data: query
  551 + }).then(res => {
  552 + this.list = res.data.list
  553 + this.total = res.data.pagination.total
  554 + this.listLoading = false
  555 + })
  556 + },
  557 + handleDel(id) {
  558 + this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
  559 + type: 'warning'
  560 + }).then(() => {
  561 + request({
  562 + url: `/api/Extend/LqKdKdjlb/${id}`,
  563 + method: 'DELETE'
  564 + }).then(res => {
  565 + this.$message({
  566 + type: 'success',
  567 + message: res.msg,
  568 + onClose: () => {
  569 + this.initData()
688 570 }
689   - }
  571 + });
  572 + })
  573 + }).catch(() => {
  574 + });
  575 + },
  576 + handleSelectionChange(val) {
  577 + const res = val.map(item => item.id)
  578 + this.multipleSelection = res
  579 + },
  580 + handleBatchRemoveDel() {
  581 + if (!this.multipleSelection.length) {
  582 + this.$message({
  583 + type: 'error',
  584 + message: '请选择一条数据',
  585 + duration: 1500,
  586 + })
  587 + return
  588 + }
  589 + const ids = this.multipleSelection
  590 + this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
  591 + type: 'warning'
  592 + }).then(() => {
  593 + request({
  594 + url: `/api/Extend/LqKdKdjlb/batchRemove`,
  595 + method: 'POST',
  596 + data: ids,
  597 + }).then(res => {
  598 + this.$message({
  599 + type: 'success',
  600 + message: res.msg,
  601 + onClose: () => {
  602 + this.initData()
  603 + }
  604 + });
  605 + })
  606 + }).catch(() => { })
  607 + },
  608 + addOrUpdateHandle(id, isDetail) {
  609 + this.formVisible = true
  610 + this.$nextTick(() => {
  611 + this.$refs.NCCForm.init(id, isDetail)
  612 + })
  613 + },
  614 + exportData() {
  615 + this.exportBoxVisible = true
  616 + this.$nextTick(() => {
  617 + this.$refs.ExportBox.init(this.columnList)
  618 + })
  619 + },
  620 + download(data) {
  621 + let query = { ...data, ...this.listQuery, ...this.query }
  622 + request({
  623 + url: `/api/Extend/LqKdKdjlb/Actions/Export`,
  624 + method: 'GET',
  625 + data: query
  626 + }).then(res => {
  627 + if (!res.data.url) return
  628 + window.location.href = this.define.comUrl + res.data.url
  629 + this.$refs.ExportBox.visible = false
  630 + this.exportBoxVisible = false
  631 + })
  632 + },
  633 + search() {
  634 + this.listQuery = {
  635 + currentPage: 1,
  636 + pageSize: 20,
  637 + sort: "desc",
  638 + sidx: "",
  639 + }
  640 + this.initData()
  641 + },
  642 + refresh(isrRefresh) {
  643 + this.formVisible = false
  644 + if (isrRefresh) this.reset()
  645 + },
  646 + reset() {
  647 + for (let key in this.query) {
  648 + this.query[key] = undefined
  649 + }
  650 + this.listQuery = {
  651 + currentPage: 1,
  652 + pageSize: 20,
  653 + sort: "desc",
  654 + sidx: "",
  655 + }
  656 + this.initData()
  657 + },
  658 + // 格式化日期
  659 + formatDate(date) {
  660 + if (!date) return '无'
  661 + const d = new Date(date)
  662 + if (isNaN(d.getTime())) return '无'
  663 + return d.toLocaleDateString('zh-CN', {
  664 + year: 'numeric',
  665 + month: '2-digit',
  666 + day: '2-digit'
  667 + })
  668 + },
  669 + // 打开会员建档弹窗
  670 + openMemberCreateDialog() {
  671 + this.memberCreateVisible = true
  672 + },
  673 + // 处理会员建档成功
  674 + handleMemberCreateSuccess(memberData) {
  675 + console.log('会员建档成功:', memberData)
  676 + // 刷新会员列表
  677 + this.getkdhyOptions()
  678 + // 自动选择新创建的会员
  679 + if (memberData && memberData.id) {
  680 + this.query.kdhy = memberData.id
  681 + this.$message.success('会员建档成功,已自动选择该会员')
  682 + }
690 683 }
  684 + }
  685 +}
691 686 </script>
692 687  
693 688 <style lang="scss" scoped>
... ... @@ -705,12 +700,12 @@
705 700 align-items: center;
706 701 justify-content: center;
707 702 gap: 6px;
708   -
  703 +
709 704 .order-icon {
710 705 color: #409EFF;
711 706 font-size: 16px;
712 707 }
713   -
  708 +
714 709 span {
715 710 font-weight: 500;
716 711 color: #303133;
... ... @@ -718,17 +713,19 @@
718 713 }
719 714  
720 715 // 会员信息样式
721   -.member-info, .member-name {
  716 +.member-info,
  717 +.member-name {
722 718 display: flex;
723 719 align-items: center;
724 720 justify-content: center;
725 721 gap: 6px;
726   -
727   - .member-icon, .member-name-icon {
  722 +
  723 + .member-icon,
  724 + .member-name-icon {
728 725 color: #67C23A;
729 726 font-size: 16px;
730 727 }
731   -
  728 +
732 729 span {
733 730 font-weight: 500;
734 731 color: #303133;
... ... @@ -741,12 +738,12 @@
741 738 align-items: center;
742 739 justify-content: center;
743 740 gap: 6px;
744   -
  741 +
745 742 .phone-icon {
746 743 color: #409EFF;
747 744 font-size: 16px;
748 745 }
749   -
  746 +
750 747 span {
751 748 font-weight: 500;
752 749 color: #303133;
... ... @@ -759,12 +756,12 @@
759 756 align-items: center;
760 757 justify-content: center;
761 758 gap: 6px;
762   -
  759 +
763 760 .store-icon {
764 761 color: #67C23A;
765 762 font-size: 16px;
766 763 }
767   -
  764 +
768 765 span {
769 766 font-weight: 500;
770 767 color: #303133;
... ... @@ -777,12 +774,12 @@
777 774 align-items: center;
778 775 justify-content: center;
779 776 gap: 6px;
780   -
  777 +
781 778 .jsj-icon {
782 779 color: #E6A23C;
783 780 font-size: 16px;
784 781 }
785   -
  782 +
786 783 span {
787 784 font-weight: 500;
788 785 color: #303133;
... ... @@ -795,12 +792,12 @@
795 792 align-items: center;
796 793 justify-content: center;
797 794 gap: 6px;
798   -
  795 +
799 796 .date-icon {
800 797 color: #909399;
801 798 font-size: 16px;
802 799 }
803   -
  800 +
804 801 span {
805 802 font-weight: 500;
806 803 color: #303133;
... ... @@ -808,17 +805,23 @@
808 805 }
809 806  
810 807 // 金额相关样式
811   -.amount-info, .paid-amount-info, .jks-amount-info, .kjb-amount-info {
  808 +.amount-info,
  809 +.paid-amount-info,
  810 +.jks-amount-info,
  811 +.kjb-amount-info {
812 812 display: flex;
813 813 align-items: center;
814 814 justify-content: center;
815 815 gap: 6px;
816   -
817   - .amount-icon, .paid-amount-icon, .jks-amount-icon, .kjb-amount-icon {
  816 +
  817 + .amount-icon,
  818 + .paid-amount-icon,
  819 + .jks-amount-icon,
  820 + .kjb-amount-icon {
818 821 color: #409EFF;
819 822 font-size: 16px;
820 823 }
821   -
  824 +
822 825 span {
823 826 font-weight: 600;
824 827 color: #409EFF;
... ... @@ -831,12 +834,12 @@
831 834 align-items: center;
832 835 justify-content: center;
833 836 gap: 6px;
834   -
  837 +
835 838 .debt-icon {
836 839 color: #F56C6C;
837 840 font-size: 16px;
838 841 }
839   -
  842 +
840 843 span {
841 844 font-weight: 500;
842 845 color: #F56C6C;
... ... @@ -849,12 +852,12 @@
849 852 align-items: center;
850 853 justify-content: center;
851 854 gap: 6px;
852   -
  855 +
853 856 .payment-icon {
854 857 color: #67C23A;
855 858 font-size: 16px;
856 859 }
857   -
  860 +
858 861 span {
859 862 font-weight: 500;
860 863 color: #303133;
... ... @@ -867,12 +870,12 @@
867 870 align-items: center;
868 871 justify-content: center;
869 872 gap: 6px;
870   -
  873 +
871 874 .source-icon {
872 875 color: #909399;
873 876 font-size: 16px;
874 877 }
875   -
  878 +
876 879 span {
877 880 font-weight: 500;
878 881 color: #303133;
... ... @@ -885,12 +888,12 @@
885 888 align-items: center;
886 889 justify-content: center;
887 890 gap: 6px;
888   -
  891 +
889 892 .referrer-icon {
890 893 color: #67C23A;
891 894 font-size: 16px;
892 895 }
893   -
  896 +
894 897 span {
895 898 font-weight: 500;
896 899 color: #303133;
... ... @@ -902,12 +905,12 @@
902 905 display: flex;
903 906 align-items: center;
904 907 gap: 6px;
905   -
  908 +
906 909 .remark-icon {
907 910 color: #909399;
908 911 font-size: 14px;
909 912 }
910   -
  913 +
911 914 span {
912 915 color: #606266;
913 916 }
... ... @@ -919,12 +922,12 @@
919 922 align-items: center;
920 923 justify-content: center;
921 924 gap: 6px;
922   -
  925 +
923 926 .customer-type-icon {
924 927 color: #67C23A;
925 928 font-size: 16px;
926 929 }
927   -
  930 +
928 931 span {
929 932 font-weight: 500;
930 933 color: #303133;
... ... @@ -937,12 +940,12 @@
937 940 align-items: center;
938 941 justify-content: center;
939 942 gap: 6px;
940   -
  943 +
941 944 .cooperation-icon {
942 945 color: #909399;
943 946 font-size: 16px;
944 947 }
945   -
  948 +
946 949 span {
947 950 font-weight: 500;
948 951 color: #303133;
... ... @@ -955,12 +958,12 @@
955 958 align-items: center;
956 959 justify-content: center;
957 960 gap: 6px;
958   -
  961 +
959 962 .storage-icon {
960 963 color: #E6A23C;
961 964 font-size: 16px;
962 965 }
963   -
  966 +
964 967 span {
965 968 font-weight: 500;
966 969 color: #303133;
... ... @@ -973,12 +976,12 @@
973 976 align-items: center;
974 977 justify-content: center;
975 978 gap: 6px;
976   -
  979 +
977 980 .storage-detail-icon {
978 981 color: #909399;
979 982 font-size: 16px;
980 983 }
981   -
  984 +
982 985 span {
983 986 font-weight: 500;
984 987 color: #303133;
... ... @@ -991,12 +994,12 @@
991 994 align-items: center;
992 995 justify-content: center;
993 996 gap: 6px;
994   -
  997 +
995 998 .hospital-icon {
996 999 color: #67C23A;
997 1000 font-size: 16px;
998 1001 }
999   -
  1002 +
1000 1003 span {
1001 1004 font-weight: 500;
1002 1005 color: #303133;
... ... @@ -1009,12 +1012,12 @@
1009 1012 align-items: center;
1010 1013 justify-content: center;
1011 1014 gap: 6px;
1012   -
  1015 +
1013 1016 .payment-judge-icon {
1014 1017 color: #409EFF;
1015 1018 font-size: 16px;
1016 1019 }
1017   -
  1020 +
1018 1021 span {
1019 1022 font-weight: 500;
1020 1023 color: #303133;
... ... @@ -1027,12 +1030,12 @@
1027 1030 align-items: center;
1028 1031 justify-content: center;
1029 1032 gap: 6px;
1030   -
  1033 +
1031 1034 .first-order-icon {
1032 1035 color: #E6A23C;
1033 1036 font-size: 16px;
1034 1037 }
1035   -
  1038 +
1036 1039 span {
1037 1040 font-weight: 500;
1038 1041 color: #303133;
... ... @@ -1045,12 +1048,12 @@
1045 1048 align-items: center;
1046 1049 justify-content: center;
1047 1050 gap: 6px;
1048   -
  1051 +
1049 1052 .intro-icon {
1050 1053 color: #909399;
1051 1054 font-size: 16px;
1052 1055 }
1053   -
  1056 +
1054 1057 span {
1055 1058 font-weight: 500;
1056 1059 color: #303133;
... ... @@ -1063,12 +1066,12 @@
1063 1066 align-items: center;
1064 1067 justify-content: center;
1065 1068 gap: 6px;
1066   -
  1069 +
1067 1070 .product-icon {
1068 1071 color: #67C23A;
1069 1072 font-size: 16px;
1070 1073 }
1071   -
  1074 +
1072 1075 span {
1073 1076 font-weight: 500;
1074 1077 color: #303133;
... ... @@ -1080,22 +1083,21 @@
1080 1083 display: flex;
1081 1084 align-items: center;
1082 1085 gap: 8px;
1083   -
  1086 +
1084 1087 .edit-btn {
1085 1088 color: #409EFF;
1086   -
  1089 +
1087 1090 &:hover {
1088 1091 color: #66b1ff;
1089 1092 }
1090 1093 }
1091   -
  1094 +
1092 1095 .delete-btn {
1093 1096 color: #F56C6C;
1094   -
  1097 +
1095 1098 &:hover {
1096 1099 color: #f78989;
1097 1100 }
1098 1101 }
1099 1102 }
1100   -
1101 1103 </style>
1102 1104 \ No newline at end of file
... ...
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqKdKdjlb/LqKdKdjlbListOutput.cs
1 1 using System;
  2 +using System.Collections.Generic;
2 3  
3 4 namespace NCC.Extend.Entitys.Dto.LqKdKdjlb
4 5 {
... ... @@ -156,5 +157,10 @@ namespace NCC.Extend.Entitys.Dto.LqKdKdjlb
156 157 /// 开单用户名称
157 158 /// </summary>
158 159 public string CreateUserName { get; set; }
  160 +
  161 + /// <summary>
  162 + /// 开单品项明细列表
  163 + /// </summary>
  164 + public List<LqKdPxmxInfoOutput> ItemDetails { get; set; }
159 165 }
160 166 }
... ...
netcore/src/Modularity/Extend/NCC.Extend/LqKdKdjlbService.cs
... ... @@ -256,6 +256,48 @@ namespace NCC.Extend.LqKdKdjlb
256 256 .MergeTable()
257 257 .OrderBy(sidx + " " + input.sort)
258 258 .ToPagedListAsync(input.currentPage, input.pageSize);
  259 +
  260 + // 获取当前页的开单记录ID列表
  261 + var billingIds = data.list.Select(x => x.id).ToList();
  262 +
  263 + // 批量查询品项明细
  264 + var itemDetails = new List<LqKdPxmxInfoOutput>();
  265 + if (billingIds.Any())
  266 + {
  267 + itemDetails = await _db.Queryable<LqKdPxmxEntity>()
  268 + .Where(x => billingIds.Contains(x.Glkdbh) && x.IsEffective == StatusEnum.有效.GetHashCode())
  269 + .Select(x => new LqKdPxmxInfoOutput
  270 + {
  271 + id = x.Id,
  272 + glkdbh = x.Glkdbh,
  273 + px = x.Px,
  274 + pxmc = x.Pxmc,
  275 + pxjg = x.Pxjg,
  276 + projectNumber = x.ProjectNumber,
  277 + isEnabled = x.IsEnabled,
  278 + sourceType = x.SourceType,
  279 + memberId = x.MemberId,
  280 + createTime = x.CreateTIme,
  281 + totalPrice = x.TotalPrice,
  282 + actualPrice = x.ActualPrice,
  283 + remark = x.Remark,
  284 + isEffective = x.IsEffective
  285 + })
  286 + .ToListAsync();
  287 + }
  288 +
  289 + // 按开单ID分组品项明细
  290 + var itemDetailsGrouped = itemDetails.GroupBy(x => x.glkdbh)
  291 + .ToDictionary(g => g.Key, g => g.ToList());
  292 +
  293 + // 为每个开单记录分配品项明细
  294 + foreach (var item in data.list)
  295 + {
  296 + item.ItemDetails = itemDetailsGrouped.ContainsKey(item.id)
  297 + ? itemDetailsGrouped[item.id]
  298 + : new List<LqKdPxmxInfoOutput>();
  299 + }
  300 +
259 301 return PageResult<LqKdKdjlbListOutput>.SqlSugarPageResult(data);
260 302 }
261 303 #endregion
... ... @@ -1751,5 +1793,7 @@ namespace NCC.Extend.LqKdKdjlb
1751 1793 }
1752 1794 }
1753 1795 #endregion
  1796 +
  1797 +
1754 1798 }
1755 1799 }
... ...
netcore/src/Modularity/Extend/NCC.Extend/LqStatisticsService.cs
... ... @@ -1464,7 +1464,7 @@ namespace NCC.Extend.LqStatistics
1464 1464 SUM(CAST(jksyj.jksyj AS DECIMAL(18,2))) as order_performance
1465 1465 FROM lq_kd_jksyj jksyj
1466 1466 INNER JOIN lq_kd_pxmx pxmx ON jksyj.F_kdpxid = pxmx.F_Id AND pxmx.F_IsEffective = 1
1467   - INNER JOIN lq_kd_kdjlb kd ON jksyj.glkdbh COLLATE utf8mb4_general_ci = kd.F_Id COLLATE utf8mb4_general_ci
  1467 + INNER JOIN lq_kd_kdjlb kd ON jksyj.glkdbh = CONVERT(kd.F_Id USING utf8mb4)
1468 1468 WHERE jksyj.yjsj IS NOT NULL
1469 1469 AND jksyj.jksyj IS NOT NULL
1470 1470 AND jksyj.jksyj != ''
... ... @@ -2529,7 +2529,7 @@ namespace NCC.Extend.LqStatistics
2529 2529 SUM(CASE WHEN kd.sfskdd = '是' THEN COALESCE(kd.zdyj, 0) ELSE 0 END) as F_FirstOrderPerformance,
2530 2530 SUM(CASE WHEN kd.sfskdd = '否' THEN COALESCE(kd.zdyj, 0) ELSE 0 END) as F_UpgradeOrderPerformance
2531 2531 FROM lq_kd_kdjlb kd
2532   - LEFT JOIN lq_mdxx md ON kd.djmd COLLATE utf8mb4_general_ci = md.F_Id COLLATE utf8mb4_general_ci
  2532 + LEFT JOIN lq_mdxx md ON CONVERT(kd.djmd USING utf8mb4) = md.F_Id
2533 2533 WHERE kd.F_IsEffective = 1
2534 2534 AND DATE_FORMAT(kd.kdrq, '%Y%m') = @statisticsMonth
2535 2535 GROUP BY kd.djmd, md.dm
... ... @@ -2539,7 +2539,7 @@ namespace NCC.Extend.LqStatistics
2539 2539 kd.djmd as F_StoreId,
2540 2540 COUNT(pxmx.F_ProjectNumber) as F_ItemQuantity
2541 2541 FROM lq_kd_kdjlb kd
2542   - LEFT JOIN lq_kd_pxmx pxmx ON kd.F_Id COLLATE utf8mb4_general_ci = pxmx.glkdbh COLLATE utf8mb4_general_ci AND pxmx.F_IsEffective = 1
  2542 + LEFT JOIN lq_kd_pxmx pxmx ON CONVERT(kd.F_Id USING utf8mb4) = pxmx.glkdbh AND pxmx.F_IsEffective = 1
2543 2543 WHERE kd.F_IsEffective = 1
2544 2544 AND DATE_FORMAT(kd.kdrq, '%Y%m') = @statisticsMonth
2545 2545 GROUP BY kd.djmd
... ...