| | |
| | | using SqlSugar; |
| | | |
| | | namespace MES.Service.service; |
| | | using DbType = System.Data.DbType; |
| | | |
| | | public class WomcaaManager : Repository<Womcaa> |
| | | { |
| | |
| | | |
| | | var orUpdate = base.Insert(mesWomcaa); |
| | | var baOrUpdate = _womcabManager.InsertRange(mesWomcabs); |
| | | |
| | | var inputParam = mesWomcaa.Erpid; |
| | | |
| | | // 使用 SqlSugar 执行存储过程 |
| | | Db.Ado.ExecuteCommand( |
| | | "BEGIN PRC_UPDATE_DAA(:P_ID); END;", |
| | | new SugarParameter("P_ID", inputParam, |
| | | DbType.Decimal)); |
| | | |
| | | if (orUpdate && baOrUpdate) return true; |
| | | throw new NotImplementedException("插入或更新失败"); |
| | | |
| | | } |
| | | |
| | | private bool UpdateData(SqlSugarScope db, Womcaa mesWomcaa, |