zhouhui.jiang

update 订单、出库、发票

Showing 25 changed files with 62 additions and 21 deletions
...@@ -141,3 +141,4 @@ public class DeliveryMainController { ...@@ -141,3 +141,4 @@ public class DeliveryMainController {
141 } 141 }
142 } 142 }
143 143
144 +
......
...@@ -87,7 +87,7 @@ public class InvoiceMainController { ...@@ -87,7 +87,7 @@ public class InvoiceMainController {
87 87
88 @Operation(summary = "删除发票", description = "根据发票ID逻辑删除发票") 88 @Operation(summary = "删除发票", description = "根据发票ID逻辑删除发票")
89 @DeleteMapping("/{invoiceId}") 89 @DeleteMapping("/{invoiceId}")
90 - @PreAuthorize("hasAuthority('invoice:delete')") 90 + @PreAuthorize("hasAuthority('invoice:remove')")
91 public ApiRes<Void> deleteInvoice( 91 public ApiRes<Void> deleteInvoice(
92 @Parameter(description = "发票ID", required = true) @PathVariable Long invoiceId) { 92 @Parameter(description = "发票ID", required = true) @PathVariable Long invoiceId) {
93 try { 93 try {
...@@ -141,3 +141,4 @@ public class InvoiceMainController { ...@@ -141,3 +141,4 @@ public class InvoiceMainController {
141 } 141 }
142 } 142 }
143 143
144 +
......
...@@ -61,3 +61,4 @@ public class DeliveryAddReq { ...@@ -61,3 +61,4 @@ public class DeliveryAddReq {
61 private List<DeliveryItemAddReq> deliveryItems; 61 private List<DeliveryItemAddReq> deliveryItems;
62 } 62 }
63 63
64 +
......
...@@ -37,3 +37,4 @@ public class DeliveryItemAddReq { ...@@ -37,3 +37,4 @@ public class DeliveryItemAddReq {
37 private BigDecimal deliveryAmount; 37 private BigDecimal deliveryAmount;
38 } 38 }
39 39
40 +
......
...@@ -59,3 +59,4 @@ public class DeliveryItemRes { ...@@ -59,3 +59,4 @@ public class DeliveryItemRes {
59 private LocalDateTime updateTime; 59 private LocalDateTime updateTime;
60 } 60 }
61 61
62 +
......
...@@ -40,3 +40,4 @@ public class DeliveryItemUpdateReq { ...@@ -40,3 +40,4 @@ public class DeliveryItemUpdateReq {
40 private BigDecimal deliveryAmount; 40 private BigDecimal deliveryAmount;
41 } 41 }
42 42
43 +
......
...@@ -67,3 +67,4 @@ public class DeliveryRes { ...@@ -67,3 +67,4 @@ public class DeliveryRes {
67 private List<DeliveryItemRes> deliveryItems; 67 private List<DeliveryItemRes> deliveryItems;
68 } 68 }
69 69
70 +
......
...@@ -65,3 +65,4 @@ public class DeliveryUpdateReq { ...@@ -65,3 +65,4 @@ public class DeliveryUpdateReq {
65 private List<DeliveryItemUpdateReq> deliveryItems; 65 private List<DeliveryItemUpdateReq> deliveryItems;
66 } 66 }
67 67
68 +
......
...@@ -42,3 +42,4 @@ public class InvoiceItemAddReq { ...@@ -42,3 +42,4 @@ public class InvoiceItemAddReq {
42 private BigDecimal taxAmount; 42 private BigDecimal taxAmount;
43 } 43 }
44 44
45 +
......
...@@ -62,3 +62,4 @@ public class InvoiceItemRes { ...@@ -62,3 +62,4 @@ public class InvoiceItemRes {
62 private LocalDateTime updateTime; 62 private LocalDateTime updateTime;
63 } 63 }
64 64
65 +
......
...@@ -45,3 +45,4 @@ public class InvoiceItemUpdateReq { ...@@ -45,3 +45,4 @@ public class InvoiceItemUpdateReq {
45 private BigDecimal taxAmount; 45 private BigDecimal taxAmount;
46 } 46 }
47 47
48 +
......
...@@ -55,3 +55,4 @@ public class InvoiceQueryReq { ...@@ -55,3 +55,4 @@ public class InvoiceQueryReq {
55 private Integer pageSize = 10; 55 private Integer pageSize = 10;
56 } 56 }
57 57
58 +
......
...@@ -66,3 +66,4 @@ public class DeliveryItem { ...@@ -66,3 +66,4 @@ public class DeliveryItem {
66 private String delFlag; 66 private String delFlag;
67 } 67 }
68 68
69 +
......
...@@ -72,3 +72,4 @@ public class InvoiceItem { ...@@ -72,3 +72,4 @@ public class InvoiceItem {
72 private String delFlag; 72 private String delFlag;
73 } 73 }
74 74
75 +
......
...@@ -81,3 +81,4 @@ public class InvoiceMain { ...@@ -81,3 +81,4 @@ public class InvoiceMain {
81 private String delFlag; 81 private String delFlag;
82 } 82 }
83 83
84 +
......
...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper; ...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper;
14 public interface DeliveryItemMapper extends BaseMapper<DeliveryItem> { 14 public interface DeliveryItemMapper extends BaseMapper<DeliveryItem> {
15 } 15 }
16 16
17 +
......
...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper; ...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper;
14 public interface DeliveryMainMapper extends BaseMapper<DeliveryMain> { 14 public interface DeliveryMainMapper extends BaseMapper<DeliveryMain> {
15 } 15 }
16 16
17 +
......
...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper; ...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper;
14 public interface InvoiceItemMapper extends BaseMapper<InvoiceItem> { 14 public interface InvoiceItemMapper extends BaseMapper<InvoiceItem> {
15 } 15 }
16 16
17 +
......
...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper; ...@@ -14,3 +14,4 @@ import org.apache.ibatis.annotations.Mapper;
14 public interface InvoiceMainMapper extends BaseMapper<InvoiceMain> { 14 public interface InvoiceMainMapper extends BaseMapper<InvoiceMain> {
15 } 15 }
16 16
17 +
......
...@@ -69,3 +69,4 @@ public interface DeliveryMainService extends IService<DeliveryMain> { ...@@ -69,3 +69,4 @@ public interface DeliveryMainService extends IService<DeliveryMain> {
69 boolean updateDeliveryStatus(Long deliveryId, Integer deliveryStatus); 69 boolean updateDeliveryStatus(Long deliveryId, Integer deliveryStatus);
70 } 70 }
71 71
72 +
......
...@@ -69,3 +69,4 @@ public interface InvoiceMainService extends IService<InvoiceMain> { ...@@ -69,3 +69,4 @@ public interface InvoiceMainService extends IService<InvoiceMain> {
69 boolean updateInvoiceStatus(Long invoiceId, Integer invoiceStatus); 69 boolean updateInvoiceStatus(Long invoiceId, Integer invoiceStatus);
70 } 70 }
71 71
72 +
......
...@@ -229,3 +229,4 @@ public class DeliveryMainServiceImpl extends ServiceImpl<DeliveryMainMapper, Del ...@@ -229,3 +229,4 @@ public class DeliveryMainServiceImpl extends ServiceImpl<DeliveryMainMapper, Del
229 } 229 }
230 } 230 }
231 231
232 +
......
...@@ -112,6 +112,7 @@ public class InvoiceMainServiceImpl extends ServiceImpl<InvoiceMainMapper, Invoi ...@@ -112,6 +112,7 @@ public class InvoiceMainServiceImpl extends ServiceImpl<InvoiceMainMapper, Invoi
112 112
113 InvoiceMain invoiceMain = new InvoiceMain(); 113 InvoiceMain invoiceMain = new InvoiceMain();
114 BeanUtils.copyProperties(addReq, invoiceMain); 114 BeanUtils.copyProperties(addReq, invoiceMain);
115 + invoiceMain.setUpdateTime(LocalDateTime.now());
115 invoiceMain.setCreateTime(LocalDateTime.now()); 116 invoiceMain.setCreateTime(LocalDateTime.now());
116 invoiceMain.setUpdateTime(LocalDateTime.now()); 117 invoiceMain.setUpdateTime(LocalDateTime.now());
117 invoiceMain.setDelFlag("0"); 118 invoiceMain.setDelFlag("0");
......
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
63 <!-- 操作按钮区域 --> 63 <!-- 操作按钮区域 -->
64 <div class="action-section"> 64 <div class="action-section">
65 <div class="action-buttons"> 65 <div class="action-buttons">
66 - <button @click="handleAdd" class="action-btn primary">➕ 新增出库</button> 66 + <button @click="handleAdd" class="action-btn primary">✨ 新增</button>
67 <button @click="handleExport" class="action-btn secondary">📋 导出</button> 67 <button @click="handleExport" class="action-btn secondary">📋 导出</button>
68 </div> 68 </div>
69 </div> 69 </div>
...@@ -175,10 +175,18 @@ ...@@ -175,10 +175,18 @@
175 <div class="dialog-body"> 175 <div class="dialog-body">
176 <div v-if="orderDetail" class="detail-content"> 176 <div v-if="orderDetail" class="detail-content">
177 <div class="detail-section"> 177 <div class="detail-section">
178 - <h4>订单基本信息</h4> 178 + <h4>出库基本信息</h4>
179 <div class="detail-grid"> 179 <div class="detail-grid">
180 <div class="detail-item"> 180 <div class="detail-item">
181 - <label>订单编号:</label> 181 + <label>出库单ID:</label>
182 + <span>{{ orderDetail.deliveryId }}</span>
183 + </div>
184 + <div class="detail-item">
185 + <label>出库单编号:</label>
186 + <span>{{ orderDetail.deliveryNo }}</span>
187 + </div>
188 + <div class="detail-item">
189 + <label>关联订单编号:</label>
182 <span>{{ orderDetail.orderNo }}</span> 190 <span>{{ orderDetail.orderNo }}</span>
183 </div> 191 </div>
184 <div class="detail-item"> 192 <div class="detail-item">
...@@ -190,12 +198,8 @@ ...@@ -190,12 +198,8 @@
190 <span>{{ orderDetail.dealerName }}</span> 198 <span>{{ orderDetail.dealerName }}</span>
191 </div> 199 </div>
192 <div class="detail-item"> 200 <div class="detail-item">
193 - <label>订单日期:</label> 201 + <label>出库日期:</label>
194 - <span>{{ formatDate(orderDetail.orderDate) }}</span> 202 + <span>{{ formatDate(orderDetail.deliveryDate) }}</span>
195 - </div>
196 - <div class="detail-item">
197 - <label>订单总金额:</label>
198 - <span>{{ formatCurrency(orderDetail.totalAmount) }}</span>
199 </div> 203 </div>
200 <div class="detail-item"> 204 <div class="detail-item">
201 <label>出库状态:</label> 205 <label>出库状态:</label>
...@@ -204,33 +208,47 @@ ...@@ -204,33 +208,47 @@
204 </span> 208 </span>
205 </div> 209 </div>
206 <div class="detail-item"> 210 <div class="detail-item">
207 - <label>出库时间:</label> 211 + <label>仓库编码:</label>
212 + <span>{{ orderDetail.warehouseCode }}</span>
213 + </div>
214 + <div class="detail-item">
215 + <label>数据来源:</label>
216 + <span>{{ orderDetail.dataSource || '-' }}</span>
217 + </div>
218 + <div class="detail-item">
219 + <label>上传时间:</label>
208 <span>{{ formatTime(orderDetail.uploadTime || '') }}</span> 220 <span>{{ formatTime(orderDetail.uploadTime || '') }}</span>
209 </div> 221 </div>
222 + <div class="detail-item">
223 + <label>创建时间:</label>
224 + <span>{{ formatTime(orderDetail.createTime || '') }}</span>
225 + </div>
226 + <div class="detail-item">
227 + <label>更新时间:</label>
228 + <span>{{ formatTime(orderDetail.updateTime || '') }}</span>
229 + </div>
210 </div> 230 </div>
211 </div> 231 </div>
212 232
213 - <div class="detail-section" v-if="orderDetail.orderItems && orderDetail.orderItems.length > 0"> 233 + <div class="detail-section" v-if="orderDetail.deliveryItems && orderDetail.deliveryItems.length > 0">
214 <h4>出库明细</h4> 234 <h4>出库明细</h4>
215 <table class="detail-table"> 235 <table class="detail-table">
216 <thead> 236 <thead>
217 <tr> 237 <tr>
218 <th>产品编码</th> 238 <th>产品编码</th>
219 <th>产品名称</th> 239 <th>产品名称</th>
220 - <th>产品型号</th> 240 + <th>出库数量</th>
221 - <th>数量</th> 241 + <th>出库单价</th>
222 - <th>单价</th> 242 + <th>出库金额</th>
223 - <th>总价</th>
224 </tr> 243 </tr>
225 </thead> 244 </thead>
226 <tbody> 245 <tbody>
227 - <tr v-for="item in orderDetail.orderItems" :key="item.itemId"> 246 + <tr v-for="item in orderDetail.deliveryItems" :key="item.deliveryItemId">
228 <td>{{ item.productCode }}</td> 247 <td>{{ item.productCode }}</td>
229 <td>{{ item.productName }}</td> 248 <td>{{ item.productName }}</td>
230 - <td>{{ item.productModel }}</td> 249 + <td>{{ item.deliveryQty }}</td>
231 - <td>{{ item.quantity }}</td> 250 + <td>{{ formatCurrency(item.deliveryPrice) }}</td>
232 - <td>{{ formatCurrency(item.unitPrice) }}</td> 251 + <td>{{ formatCurrency(item.deliveryAmount) }}</td>
233 - <td>{{ formatCurrency(item.totalPrice) }}</td>
234 </tr> 252 </tr>
235 </tbody> 253 </tbody>
236 </table> 254 </table>
......
This diff is collapsed. Click to expand it.