fix
wangpengfei
2023-08-30 18a4518b5bc98edb78649ad3b864d019b06a8609
fix

fix update function from save to updates
5个文件已修改
10 ■■■■ 已修改文件
service/test/contract.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
service/test/industry.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
service/test/member.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
service/test/product.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
service/test/supplier_type.go 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
service/test/contract.go
@@ -34,7 +34,7 @@
// UpdateContract 更新Contract记录
// Author [piexlmax](https://github.com/piexlmax)
func (conService *ContractService) UpdateContract(con test.Contract) (err error) {
    err = global.GVA_DB.Save(&con).Error
    err = global.GVA_DB.Updates(&con).Error
    return err
}
service/test/industry.go
@@ -34,7 +34,7 @@
// UpdateIndustry 更新Industry记录
// Author [piexlmax](https://github.com/piexlmax)
func (iService *IndustryService) UpdateIndustry(i test.Industry) (err error) {
    err = global.GVA_DB.Save(&i).Error
    err = global.GVA_DB.Updates(&i).Error
    return err
}
service/test/member.go
@@ -34,7 +34,7 @@
// UpdateMember 更新Member记录
// Author [piexlmax](https://github.com/piexlmax)
func (mService *MemberService) UpdateMember(m test.Member) (err error) {
    err = global.GVA_DB.Save(&m).Error
    err = global.GVA_DB.Updates(&m).Error
    return err
}
service/test/product.go
@@ -34,7 +34,7 @@
// UpdateProduct 更新Product记录
// Author [piexlmax](https://github.com/piexlmax)
func (pService *ProductService) UpdateProduct(p test.Product) (err error) {
    err = global.GVA_DB.Save(&p).Error
    err = global.GVA_DB.Updates(&p).Error
    return err
}
service/test/supplier_type.go
@@ -34,7 +34,7 @@
// UpdateSupplierType 更新SupplierType记录
// Author [piexlmax](https://github.com/piexlmax)
func (stService *SupplierTypeService) UpdateSupplierType(st test.SupplierType) (err error) {
    err = global.GVA_DB.Save(&st).Error
    err = global.GVA_DB.Updates(&st).Error
    return err
}