...
This commit is contained in:
@@ -114,7 +114,8 @@ namespace Back.Controllers
|
||||
|
||||
////-----change Cod
|
||||
Cod.TaxRate = item.TaxRate;
|
||||
//Cod.Title = item.Title;
|
||||
if(!await _servCOD.UsedInTheInvoice(Cod.ID))
|
||||
Cod.Title = item.Title;
|
||||
Cod.UnitID = item.UnitID;
|
||||
Cod.ItemTaxID = item.TaxID;
|
||||
Cod.IsDeleted = false;
|
||||
@@ -138,5 +139,10 @@ namespace Back.Controllers
|
||||
//----Update and sendResult
|
||||
return Ok(await _servCOD.DeleteCod(cod));
|
||||
}
|
||||
[HttpGet("UsedInTheInvoice/{ID}")]
|
||||
public async Task<ActionResult<bool>> UsedInTheInvoice(int ID)
|
||||
{
|
||||
return Ok(await _servCOD.UsedInTheInvoice(ID));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -130,7 +130,8 @@ namespace Back.Controllers
|
||||
cus.CustomerType = item.CustomerType;
|
||||
cus.EconomicCode = item.EconomicCode;
|
||||
cus.Email = item.Email;
|
||||
// cus.FullName = item.FullName;
|
||||
if(!await _servCus.UsedInTheInvoice(cus.ID))
|
||||
cus.FullName = item.FullName;
|
||||
cus.Info = item.Info;
|
||||
cus.MeliCode = item.MeliCode;
|
||||
cus.PassportNumber = item.PassportNumber;
|
||||
@@ -157,5 +158,10 @@ namespace Back.Controllers
|
||||
//----Update and sendResult
|
||||
return Ok(await _servCus.DeleteCustomer(cus));
|
||||
}
|
||||
[HttpGet("UsedInTheInvoice/{ID}")]
|
||||
public async Task<ActionResult<bool>> UsedInTheInvoice(int ID)
|
||||
{
|
||||
return Ok(await _servCus.UsedInTheInvoice(ID));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user