| | |
| | | List<Womcab> mesWomcabs) |
| | | { |
| | | var decimals = mesWomcabs.Select(s => s.Id).ToArray(); |
| | | var update = base.DeleteById(mesWomcaa.Id); |
| | | var insertOrUpdate = db |
| | | .Deleteable<Womcab>().In(decimals) |
| | | .ExecuteCommand() > 0; |
| | | |
| | | var update = true; |
| | | if (mesWomcaa != null) |
| | | { |
| | | if (mesWomcaa.Id != null) |
| | | { |
| | | update = base.DeleteById(mesWomcaa.Id); |
| | | } |
| | | } |
| | | var insertOrUpdate = true; |
| | | if (decimals != null || decimals.Length > 0) |
| | | { |
| | | insertOrUpdate = db.Deleteable<Womcab>().In(decimals).ExecuteCommand() > 0; |
| | | } |
| | | |
| | | if (update && insertOrUpdate) return true; |
| | | if (update && insertOrUpdate) |
| | | { |
| | | return true; |
| | | } |
| | | throw new NotImplementedException("更新失败"); |
| | | |
| | | } |
| | | |
| | | private Womcaa MapErpCAAtoWomcaa(ErpCAA dto) |
| | |
| | | Jt=dto.JT, |
| | | Xscn=dto.XS_CN, |
| | | Sjxs=dto.SJ_xs, |
| | | Nextgx=dto.NEXT_Gx |
| | | Nextgx=dto.NEXT_Gx, |
| | | Rks=dto.RKS, |
| | | //沃尔新增 |
| | | // WR_F_SCDD_SCTZD = dto.F_SCDD_SCTZD |
| | | //WR_F_SCDD_XH = dto.F_SCDD_XH |
| | |
| | | // Db.Deleteable<Womcab>().Where(s => s.Erpid == womcab.Erpid).ExecuteCommand(); |
| | | womcab.Id = entity.Id; |
| | | } |
| | | |
| | | womcabList.Add(womcab); |
| | | } |
| | | |