Documentation
¶
Overview ¶
Declares the package name
Declares the package name ¶
Declares the package name ¶
Declares the package name ¶
Declares the package name ¶
Declares the package name ¶
Declares the package name ¶
Declares the package name
Index ¶
- Variables
- func NewAppointmentGrpcHandler(p_oGrpcService appointmentService) appointmentGrpcHandler
- func NewAppointmentHandler(p_oService appointmentService) appointmentHandler
- func NewAppointmentRepository(p_oDatabase *sqlx.DB) appointmentRepository
- func NewAppointmentService() appointmentService
- func NewAppointmentServiceWithDB(p_oRepo Repository) appointmentService
- func RegisterAppointmentServiceServer(s grpc.ServiceRegistrar, srv AppointmentServiceServer)
- func RouterInit(r fiber.Router)
- func RouterInitGRPC(server *grpc.Server, db *sqlx.DB)
- func RouterInitWithDB(r fiber.Router, dbx *sqlx.DB)
- type Appointment
- type AppointmentAddProto
- func (*AppointmentAddProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentAddProto) GetAddappointment() *AppointmentProto
- func (*AppointmentAddProto) ProtoMessage()
- func (x *AppointmentAddProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentAddProto) Reset()
- func (x *AppointmentAddProto) String() string
- type AppointmentDeleteProto
- func (*AppointmentDeleteProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentDeleteProto) GetDeleteappointment() *AppointmentProto
- func (*AppointmentDeleteProto) ProtoMessage()
- func (x *AppointmentDeleteProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentDeleteProto) Reset()
- func (x *AppointmentDeleteProto) String() string
- type AppointmentDeleteResponseProto
- func (*AppointmentDeleteResponseProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentDeleteResponseProto) GetAppointmentNo() string
- func (x *AppointmentDeleteResponseProto) GetHealthcareId() string
- func (*AppointmentDeleteResponseProto) ProtoMessage()
- func (x *AppointmentDeleteResponseProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentDeleteResponseProto) Reset()
- func (x *AppointmentDeleteResponseProto) String() string
- type AppointmentGetProto
- func (*AppointmentGetProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentGetProto) GetAppointmentNo() string
- func (x *AppointmentGetProto) GetHealthcareId() string
- func (*AppointmentGetProto) ProtoMessage()
- func (x *AppointmentGetProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentGetProto) Reset()
- func (x *AppointmentGetProto) String() string
- type AppointmentListProto
- func (*AppointmentListProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentListProto) GetAppointments() []*AppointmentProto
- func (*AppointmentListProto) ProtoMessage()
- func (x *AppointmentListProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentListProto) Reset()
- func (x *AppointmentListProto) String() string
- type AppointmentListResponse
- type AppointmentProto
- func (*AppointmentProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentProto) GetAppointmentDate() *timestamppb.Timestamp
- func (x *AppointmentProto) GetAppointmentNo() string
- func (x *AppointmentProto) GetAppointmentTime() *timestamppb.Timestamp
- func (x *AppointmentProto) GetCreateAt() *timestamppb.Timestamp
- func (x *AppointmentProto) GetHealthcareId() string
- func (x *AppointmentProto) GetIsVoid() bool
- func (x *AppointmentProto) GetParamedicId() string
- func (x *AppointmentProto) GetPatientId() string
- func (x *AppointmentProto) GetScheduleSlotId() int64
- func (x *AppointmentProto) GetUserCreate() string
- func (*AppointmentProto) ProtoMessage()
- func (x *AppointmentProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentProto) Reset()
- func (x *AppointmentProto) String() string
- type AppointmentRequest
- type AppointmentServiceClient
- type AppointmentServiceServer
- type AppointmentUpdateProto
- func (*AppointmentUpdateProto) Descriptor() ([]byte, []int)deprecated
- func (x *AppointmentUpdateProto) GetUpdateappointment() *AppointmentProto
- func (*AppointmentUpdateProto) ProtoMessage()
- func (x *AppointmentUpdateProto) ProtoReflect() protoreflect.Message
- func (x *AppointmentUpdateProto) Reset()
- func (x *AppointmentUpdateProto) String() string
- type ErrorResponse
- type Repository
- type UnimplementedAppointmentServiceServer
- func (UnimplementedAppointmentServiceServer) Add(context.Context, *AppointmentAddProto) (*AppointmentProto, error)
- func (UnimplementedAppointmentServiceServer) Delete(context.Context, *AppointmentDeleteProto) (*AppointmentDeleteResponseProto, error)
- func (UnimplementedAppointmentServiceServer) Get(context.Context, *AppointmentGetProto) (*AppointmentProto, error)
- func (UnimplementedAppointmentServiceServer) List(context.Context, *emptypb.Empty) (*AppointmentListProto, error)
- func (UnimplementedAppointmentServiceServer) ListByParam(context.Context, *AppointmentProto) (*AppointmentListProto, error)
- func (UnimplementedAppointmentServiceServer) Update(context.Context, *AppointmentUpdateProto) (*AppointmentProto, error)
- type UnsafeAppointmentServiceServer
Constants ¶
This section is empty.
Variables ¶
var AppointmentService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "appointment.AppointmentService", HandlerType: (*AppointmentServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "List", Handler: _AppointmentService_List_Handler, }, { MethodName: "ListByParam", Handler: _AppointmentService_ListByParam_Handler, }, { MethodName: "Get", Handler: _AppointmentService_Get_Handler, }, { MethodName: "Add", Handler: _AppointmentService_Add_Handler, }, { MethodName: "Update", Handler: _AppointmentService_Update_Handler, }, { MethodName: "Delete", Handler: _AppointmentService_Delete_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "domain/appointment/proto/appointment.proto", }
AppointmentService_ServiceDesc is the grpc.ServiceDesc for AppointmentService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_domain_appointment_proto_appointment_proto protoreflect.FileDescriptor
Functions ¶
func NewAppointmentGrpcHandler ¶
func NewAppointmentGrpcHandler(p_oGrpcService appointmentService) appointmentGrpcHandler
Declare Appointment GRPC Handler @Param appointmentService aka p_oGrpcService
func NewAppointmentHandler ¶
func NewAppointmentHandler(p_oService appointmentService) appointmentHandler
Declare Appointment Handler @Param appointmentService aka p_oService
func NewAppointmentRepository ¶
Declare Appointment Repository
func NewAppointmentService ¶
func NewAppointmentService() appointmentService
Declare Appointment Service
func NewAppointmentServiceWithDB ¶
func NewAppointmentServiceWithDB(p_oRepo Repository) appointmentService
func RegisterAppointmentServiceServer ¶
func RegisterAppointmentServiceServer(s grpc.ServiceRegistrar, srv AppointmentServiceServer)
func RouterInit ¶
func RouterInit(r fiber.Router)
func RouterInitWithDB ¶
Types ¶
type Appointment ¶
type Appointment struct { HealthcareId string `db:"healthcare_id"` AppointmentNo string `db:"appointment_no"` ParamedicId string `db:"paramedic_id"` PatientId string `db:"patient_id"` AppointmentDate time.Time `db:"appointment_date"` AppointmentTime time.Time `db:"appointment_time"` IsVoid bool `db:"is_void"` UserCreate string `db:"user_create"` CreateAt time.Time `db:"create_at"` ScheduleSlotId int `db:"schedule_slot_id"` }
Declare Appointment Entity
func (*Appointment) ParseToAppointmentProto ¶ added in v0.0.2
func (a *Appointment) ParseToAppointmentProto() *AppointmentProto
type AppointmentAddProto ¶
type AppointmentAddProto struct { Addappointment *AppointmentProto `protobuf:"bytes,1,opt,name=addappointment,proto3" json:"addappointment,omitempty"` // contains filtered or unexported fields }
Add appointment
func (*AppointmentAddProto) Descriptor
deprecated
func (*AppointmentAddProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentAddProto.ProtoReflect.Descriptor instead.
func (*AppointmentAddProto) GetAddappointment ¶
func (x *AppointmentAddProto) GetAddappointment() *AppointmentProto
func (*AppointmentAddProto) ProtoMessage ¶
func (*AppointmentAddProto) ProtoMessage()
func (*AppointmentAddProto) ProtoReflect ¶
func (x *AppointmentAddProto) ProtoReflect() protoreflect.Message
func (*AppointmentAddProto) Reset ¶
func (x *AppointmentAddProto) Reset()
func (*AppointmentAddProto) String ¶
func (x *AppointmentAddProto) String() string
type AppointmentDeleteProto ¶
type AppointmentDeleteProto struct { Deleteappointment *AppointmentProto `protobuf:"bytes,1,opt,name=deleteappointment,proto3" json:"deleteappointment,omitempty"` // contains filtered or unexported fields }
Delete appointment
func (*AppointmentDeleteProto) Descriptor
deprecated
func (*AppointmentDeleteProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentDeleteProto.ProtoReflect.Descriptor instead.
func (*AppointmentDeleteProto) GetDeleteappointment ¶
func (x *AppointmentDeleteProto) GetDeleteappointment() *AppointmentProto
func (*AppointmentDeleteProto) ProtoMessage ¶
func (*AppointmentDeleteProto) ProtoMessage()
func (*AppointmentDeleteProto) ProtoReflect ¶
func (x *AppointmentDeleteProto) ProtoReflect() protoreflect.Message
func (*AppointmentDeleteProto) Reset ¶
func (x *AppointmentDeleteProto) Reset()
func (*AppointmentDeleteProto) String ¶
func (x *AppointmentDeleteProto) String() string
type AppointmentDeleteResponseProto ¶
type AppointmentDeleteResponseProto struct { HealthcareId string `protobuf:"bytes,1,opt,name=healthcare_id,json=healthcareId,proto3" json:"healthcare_id,omitempty"` AppointmentNo string `protobuf:"bytes,2,opt,name=appointment_no,json=appointmentNo,proto3" json:"appointment_no,omitempty"` // contains filtered or unexported fields }
[Response] Delete appointment
func (*AppointmentDeleteResponseProto) Descriptor
deprecated
func (*AppointmentDeleteResponseProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentDeleteResponseProto.ProtoReflect.Descriptor instead.
func (*AppointmentDeleteResponseProto) GetAppointmentNo ¶
func (x *AppointmentDeleteResponseProto) GetAppointmentNo() string
func (*AppointmentDeleteResponseProto) GetHealthcareId ¶
func (x *AppointmentDeleteResponseProto) GetHealthcareId() string
func (*AppointmentDeleteResponseProto) ProtoMessage ¶
func (*AppointmentDeleteResponseProto) ProtoMessage()
func (*AppointmentDeleteResponseProto) ProtoReflect ¶
func (x *AppointmentDeleteResponseProto) ProtoReflect() protoreflect.Message
func (*AppointmentDeleteResponseProto) Reset ¶
func (x *AppointmentDeleteResponseProto) Reset()
func (*AppointmentDeleteResponseProto) String ¶
func (x *AppointmentDeleteResponseProto) String() string
type AppointmentGetProto ¶
type AppointmentGetProto struct { HealthcareId string `protobuf:"bytes,1,opt,name=healthcare_id,json=healthcareId,proto3" json:"healthcare_id,omitempty"` AppointmentNo string `protobuf:"bytes,2,opt,name=appointment_no,json=appointmentNo,proto3" json:"appointment_no,omitempty"` // contains filtered or unexported fields }
Get appointment based on Healthcare ID and Appointment No
func (*AppointmentGetProto) Descriptor
deprecated
func (*AppointmentGetProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentGetProto.ProtoReflect.Descriptor instead.
func (*AppointmentGetProto) GetAppointmentNo ¶
func (x *AppointmentGetProto) GetAppointmentNo() string
func (*AppointmentGetProto) GetHealthcareId ¶
func (x *AppointmentGetProto) GetHealthcareId() string
func (*AppointmentGetProto) ProtoMessage ¶
func (*AppointmentGetProto) ProtoMessage()
func (*AppointmentGetProto) ProtoReflect ¶
func (x *AppointmentGetProto) ProtoReflect() protoreflect.Message
func (*AppointmentGetProto) Reset ¶
func (x *AppointmentGetProto) Reset()
func (*AppointmentGetProto) String ¶
func (x *AppointmentGetProto) String() string
type AppointmentListProto ¶
type AppointmentListProto struct { Appointments []*AppointmentProto `protobuf:"bytes,1,rep,name=appointments,proto3" json:"appointments,omitempty"` // contains filtered or unexported fields }
[Response] Get appointment list
func (*AppointmentListProto) Descriptor
deprecated
func (*AppointmentListProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentListProto.ProtoReflect.Descriptor instead.
func (*AppointmentListProto) GetAppointments ¶
func (x *AppointmentListProto) GetAppointments() []*AppointmentProto
func (*AppointmentListProto) ProtoMessage ¶
func (*AppointmentListProto) ProtoMessage()
func (*AppointmentListProto) ProtoReflect ¶
func (x *AppointmentListProto) ProtoReflect() protoreflect.Message
func (*AppointmentListProto) Reset ¶
func (x *AppointmentListProto) Reset()
func (*AppointmentListProto) String ¶
func (x *AppointmentListProto) String() string
type AppointmentListResponse ¶
type AppointmentListResponse struct { HealthcareId string `json:"HealthcareId"` AppointmentNo string `json:"AppointmentNo"` ParamedicId string `json:"ParamedicId"` PatientId string `json:"PatientId"` AppointmentDate time.Time `json:"AppointmentDate"` AppointmentTime time.Time `json:"AppointmentTime"` IsVoid bool `json:"IsVoid"` UserCreate string `json:"UserCreate"` CreateAt time.Time `json:"CreateAt"` ScheduleSlotId int `json:"ScheduleSlotId"` }
[Response] Declare Appointment List construct
type AppointmentProto ¶
type AppointmentProto struct { HealthcareId string `protobuf:"bytes,1,opt,name=healthcare_id,json=healthcareId,proto3" json:"healthcare_id,omitempty"` AppointmentNo string `protobuf:"bytes,2,opt,name=appointment_no,json=appointmentNo,proto3" json:"appointment_no,omitempty"` ParamedicId string `protobuf:"bytes,3,opt,name=paramedic_id,json=paramedicId,proto3" json:"paramedic_id,omitempty"` PatientId string `protobuf:"bytes,4,opt,name=patient_id,json=patientId,proto3" json:"patient_id,omitempty"` AppointmentDate *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=appointment_date,json=appointmentDate,proto3" json:"appointment_date,omitempty"` AppointmentTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=appointment_time,json=appointmentTime,proto3" json:"appointment_time,omitempty"` IsVoid bool `protobuf:"varint,7,opt,name=is_void,json=isVoid,proto3" json:"is_void,omitempty"` UserCreate string `protobuf:"bytes,8,opt,name=user_create,json=userCreate,proto3" json:"user_create,omitempty"` CreateAt *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=create_at,json=createAt,proto3" json:"create_at,omitempty"` ScheduleSlotId int64 `protobuf:"varint,10,opt,name=schedule_slot_id,json=scheduleSlotId,proto3" json:"schedule_slot_id,omitempty"` // contains filtered or unexported fields }
[Response] Get appointment
func (*AppointmentProto) Descriptor
deprecated
func (*AppointmentProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentProto.ProtoReflect.Descriptor instead.
func (*AppointmentProto) GetAppointmentDate ¶
func (x *AppointmentProto) GetAppointmentDate() *timestamppb.Timestamp
func (*AppointmentProto) GetAppointmentNo ¶
func (x *AppointmentProto) GetAppointmentNo() string
func (*AppointmentProto) GetAppointmentTime ¶
func (x *AppointmentProto) GetAppointmentTime() *timestamppb.Timestamp
func (*AppointmentProto) GetCreateAt ¶
func (x *AppointmentProto) GetCreateAt() *timestamppb.Timestamp
func (*AppointmentProto) GetHealthcareId ¶
func (x *AppointmentProto) GetHealthcareId() string
func (*AppointmentProto) GetIsVoid ¶
func (x *AppointmentProto) GetIsVoid() bool
func (*AppointmentProto) GetParamedicId ¶
func (x *AppointmentProto) GetParamedicId() string
func (*AppointmentProto) GetPatientId ¶
func (x *AppointmentProto) GetPatientId() string
func (*AppointmentProto) GetScheduleSlotId ¶
func (x *AppointmentProto) GetScheduleSlotId() int64
func (*AppointmentProto) GetUserCreate ¶
func (x *AppointmentProto) GetUserCreate() string
func (*AppointmentProto) ProtoMessage ¶
func (*AppointmentProto) ProtoMessage()
func (*AppointmentProto) ProtoReflect ¶
func (x *AppointmentProto) ProtoReflect() protoreflect.Message
func (*AppointmentProto) Reset ¶
func (x *AppointmentProto) Reset()
func (*AppointmentProto) String ¶
func (x *AppointmentProto) String() string
type AppointmentRequest ¶
type AppointmentRequest struct { HealthcareId string `json:"HealthcareId"` AppointmentNo string `json:"AppointmentNo"` ParamedicId string `json:"ParamedicId"` PatientId string `json:"PatientId"` AppointmentDate time.Time `json:"AppointmentDate"` AppointmentTime time.Time `json:"AppointmentTime"` IsVoid bool `json:"IsVoid"` UserCreate string `json:"UserCreate"` CreateAt time.Time `json:"CreateAt"` ScheduleSlotId int `json:"ScheduleSlotId"` }
[Request] Declare Appointment List construct
func (AppointmentRequest) ParseToEntity ¶
func (a AppointmentRequest) ParseToEntity() Appointment
Convert Object to Entity
func (AppointmentRequest) Validate ¶
func (a AppointmentRequest) Validate() (err error)
Validate Data Request
type AppointmentServiceClient ¶
type AppointmentServiceClient interface { List(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*AppointmentListProto, error) ListByParam(ctx context.Context, in *AppointmentProto, opts ...grpc.CallOption) (*AppointmentListProto, error) Get(ctx context.Context, in *AppointmentGetProto, opts ...grpc.CallOption) (*AppointmentProto, error) Add(ctx context.Context, in *AppointmentAddProto, opts ...grpc.CallOption) (*AppointmentProto, error) Update(ctx context.Context, in *AppointmentUpdateProto, opts ...grpc.CallOption) (*AppointmentProto, error) Delete(ctx context.Context, in *AppointmentDeleteProto, opts ...grpc.CallOption) (*AppointmentDeleteResponseProto, error) }
AppointmentServiceClient is the client API for AppointmentService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewAppointmentServiceClient ¶
func NewAppointmentServiceClient(cc grpc.ClientConnInterface) AppointmentServiceClient
type AppointmentServiceServer ¶
type AppointmentServiceServer interface { List(context.Context, *emptypb.Empty) (*AppointmentListProto, error) ListByParam(context.Context, *AppointmentProto) (*AppointmentListProto, error) Get(context.Context, *AppointmentGetProto) (*AppointmentProto, error) Add(context.Context, *AppointmentAddProto) (*AppointmentProto, error) Update(context.Context, *AppointmentUpdateProto) (*AppointmentProto, error) Delete(context.Context, *AppointmentDeleteProto) (*AppointmentDeleteResponseProto, error) // contains filtered or unexported methods }
AppointmentServiceServer is the server API for AppointmentService service. All implementations must embed UnimplementedAppointmentServiceServer for forward compatibility
type AppointmentUpdateProto ¶
type AppointmentUpdateProto struct { Updateappointment *AppointmentProto `protobuf:"bytes,1,opt,name=updateappointment,proto3" json:"updateappointment,omitempty"` // contains filtered or unexported fields }
Update appointment
func (*AppointmentUpdateProto) Descriptor
deprecated
func (*AppointmentUpdateProto) Descriptor() ([]byte, []int)
Deprecated: Use AppointmentUpdateProto.ProtoReflect.Descriptor instead.
func (*AppointmentUpdateProto) GetUpdateappointment ¶
func (x *AppointmentUpdateProto) GetUpdateappointment() *AppointmentProto
func (*AppointmentUpdateProto) ProtoMessage ¶
func (*AppointmentUpdateProto) ProtoMessage()
func (*AppointmentUpdateProto) ProtoReflect ¶
func (x *AppointmentUpdateProto) ProtoReflect() protoreflect.Message
func (*AppointmentUpdateProto) Reset ¶
func (x *AppointmentUpdateProto) Reset()
func (*AppointmentUpdateProto) String ¶
func (x *AppointmentUpdateProto) String() string
type ErrorResponse ¶
func ValidateStruct ¶
func ValidateStruct(user interface{}) []ErrorResponse
type Repository ¶
type Repository interface { ListRepo(ctx context.Context) ([]Appointment, error) GetRepo(ctx context.Context, m_strHealthcareId string, m_strAppointmentNo string) ([]Appointment, error) AddRepo(ctx context.Context, app Appointment) (p_strAppointmentNo string, err error) }
Appointment Repository Interface
type UnimplementedAppointmentServiceServer ¶
type UnimplementedAppointmentServiceServer struct { }
UnimplementedAppointmentServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedAppointmentServiceServer) Add ¶
func (UnimplementedAppointmentServiceServer) Add(context.Context, *AppointmentAddProto) (*AppointmentProto, error)
func (UnimplementedAppointmentServiceServer) Get ¶
func (UnimplementedAppointmentServiceServer) Get(context.Context, *AppointmentGetProto) (*AppointmentProto, error)
func (UnimplementedAppointmentServiceServer) List ¶
func (UnimplementedAppointmentServiceServer) List(context.Context, *emptypb.Empty) (*AppointmentListProto, error)
func (UnimplementedAppointmentServiceServer) ListByParam ¶
func (UnimplementedAppointmentServiceServer) ListByParam(context.Context, *AppointmentProto) (*AppointmentListProto, error)
func (UnimplementedAppointmentServiceServer) Update ¶
func (UnimplementedAppointmentServiceServer) Update(context.Context, *AppointmentUpdateProto) (*AppointmentProto, error)
type UnsafeAppointmentServiceServer ¶
type UnsafeAppointmentServiceServer interface {
// contains filtered or unexported methods
}
UnsafeAppointmentServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AppointmentServiceServer will result in compilation errors.