jacky-htg / ledger-service

General Ledger service using golang grpc and postgresql. This service is part of inventory microservices.
GNU General Public License v3.0
3 stars 0 forks source link

Receivable Service #18

Open jacky-htg opened 1 year ago

jacky-htg commented 1 year ago

see file of proto/ledgers/receivable_service.proto

jacky-htg commented 1 year ago
message Receivable {
  string id = 1;
  string company_id = 2;
  string sales_id = 3;
  string sales_code = 4;
  string customer_id = 5;
  string customer_name = 6;
  string due_date = 7;
  double amount_owed = 8;
  double amount_paid = 9;
  string payment_status = 10; 
  bytes payments = 11;
}

message Receivables {
  repeated Receivable receivable = 1;
}
message ViewByCustomerIdInput {
  string id = 1;
  string period = 2;
}

service ReceivableService {
  rpc Create(Receivable) returns (Receivable) {}
  rpc ViewByCustomerId(ViewByCustomerIdInput) returns (Receivables) {}
  rpc ViewBySalesId(Id) returns (Receivable) {}
}