public Boolean Post([FromBody] Customer customer) { CustomerAC customerAC = new CustomerAC(); var affectRows = customerAC.InsertCustomer(customer); if (affectRows == -1) { return(false); } else { return(true); } }
public string ToText() // to write a record line in a text file { return(CustomerName + "," + CustomerAC.ToString() + "," + CustomerType.ToString() + "," + CustomerCharge.ToString()); }
public override string ToString() // overriding toString() method to read record line from file { return(CustomerName + "," + CustomerAC.ToString() + "," + CustomerType.ToString() + "," + CustomerCharge.ToString("c")); }