From e1c0fe2768d32f79920ceda92383981d4ff12058 Mon Sep 17 00:00:00 2001
From: liujiandao <274878379@qq.com>
Date: 星期五, 15 三月 2024 10:07:50 +0800
Subject: [PATCH] 获取销售明细产品信息
---
service/contract.go | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/service/contract.go b/service/contract.go
index 2072299..b6825ef 100644
--- a/service/contract.go
+++ b/service/contract.go
@@ -31,18 +31,18 @@
return ecode.OK
}
-func (ContractService) GetContractList(page, pageSize int, data map[string]interface{}) ([]*model.Contract, int64, int) {
+func (ContractService) GetContractList(page, pageSize int, data map[string]interface{}, keyword string) ([]*model.Contract, int64, int) {
// get contact list
- contacts, total, err := model.NewContractSearch().SetPage(page, pageSize).SetSearchMap(data).FindAll()
+ contacts, total, err := model.NewContractSearch().SetPage(page, pageSize).SetSearchMap(data).SetKeyword(keyword).FindAll()
if err != nil {
return nil, 0, ecode.ContractListErr
}
return contacts, total, ecode.OK
}
-func (ContractService) DeleteContract(ids []int) int {
+func (ContractService) DeleteContract(id int) int {
// delete client
- err := model.NewContractSearch().SetIds(ids).Delete()
+ err := model.NewContractSearch().SetId(id).Delete()
if err != nil {
return ecode.ContractDeleteErr
}
--
Gitblit v1.8.0