You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: customer.go
    path of file: ./repos/api-server/app/models
    
    the code of the file until where you have to start completion: package models

import (
	"github.com/pkg/errors"
	"gorm.io/gorm"
	"gorm.io/gorm/clause"
	"openscrm/app/requests"
	app "openscrm/common/app"
	"time"
)

type CustomerExportItem struct {
	ExtID            string          `gorm:"type:char(64);uniqueIndex:idx_ext_customer_id;comment:微信定义的userID
    
func (o Customer) Get(ID string, extCorpID string, withStaffRelation bool) (*Customer, error) {
	customer := Customer{}
	db := DB.Model(&Customer{}).Where("id = ? and ext_corp_id = ?", ID, extCorpID)
	if withStaffRelation {
		db = db.Preload("Staffs").Preload("Staffs.CustomerStaffTags")
	}
	err := db.Find(&customer).Error
	if err != nil {
		err = errors.Wrap(err, "Get customer by id failed")
		return &customer, err
	}
	return &customer, nil
}