Ver código fonte

feature(计费): 表字段新增和变更

likai 4 anos atrás
pai
commit
0e4292762d

+ 58 - 16
dao/account/internal/settle_account_bill.go

@@ -26,22 +26,36 @@ type SettleAccountBillDao struct {
 
 // SettleAccountBillColumns defines and stores column names for table settle_account_bill.
 type settleAccountBillColumns struct {
-	Id                     string // 主键
-	Code                   string // 账单号
-	TotalCount             string // 账单总额
-	SettleTime             string // 结算时间
-	StartDate              string // 账单开始时间
-	EndDate                string // 账单结束时间
-	Status                 string // 账单状态  1待确认 2待核销 4已核销
-	ActualVerificationDate string // 实际核销时间
-	ActualVerificationUser string // 实际核销人
-	VerificationUserId     string // 核销人Id
-	VerificationUser       string // 核销人
-	VerificationDate       string // 完成核销时间
-	CreateUserId           string //
-	CreateBy               string //
-	CreateOn               string //
-	DeletedAt              string // 删除时间
+	Id                      string // 主键
+	Code                    string // 账单号
+	TotalCount              string // 计费总额
+	SettleTime              string // 结算时间
+	StartDate               string // 账单开始时间
+	EndDate                 string // 账单结束时间
+	Status                  string // 账单状态 0未确认 1已确认 2已结算 3已扣款
+	ActualVerificationDate  string // 实际核销时间
+	ActualVerificationUser  string // 实际核销人
+	VerificationUserId      string // 核销人Id
+	VerificationUser        string // 核销人
+	VerificationDate        string // 完成核销时间
+	CreateUserId            string //
+	CreateBy                string //
+	CreateOn                string //
+	DeletedAt               string // 删除时间
+	MainUserId              string // 主用户Id
+	MainUser                string // 主用户
+	AccountId               string // 经费账号Id
+	PaymentDueDate          string // 付款截止日期
+	SettlementDateUserId    string // 结算人Id
+	SettlementDateUser      string // 结算人
+	SettlementDate          string // 结算时间
+	DeductMoneyUserId       string // 扣款人Id
+	DeductMoneyUser         string // 扣款人
+	DeductMoneyDate         string // 扣款时间
+	Remark                  string // 备注
+	UpdateUserId            string // 更新者ID
+	UpdateBy                string // 更新者
+	UpdateOn                string // 更新时间
 }
 
 var (
@@ -67,6 +81,20 @@ var (
 			CreateBy:               "CreateBy",
 			CreateOn:               "CreateOn",
 			DeletedAt:              "DeletedAt",
+			MainUserId:             "MainUserId",
+			MainUser:               "MainUser",
+			AccountId:              "AccountId",
+			PaymentDueDate:         "PaymentDueDate",
+			SettlementDateUserId:   "SettlementDateUserId",
+			SettlementDateUser:     "SettlementDateUser",
+			SettlementDate:         "SettlementDate",
+			DeductMoneyUserId:      "DeductMoneyUserId",
+			DeductMoneyUser:        "DeductMoneyUser",
+			DeductMoneyDate:        "DeductMoneyDate",
+			Remark:                 "Remark",
+			UpdateUserId:           "UpdateUserId",
+			UpdateBy:               "UpdateBy",
+			UpdateOn:               "UpdateOn",
 		},
 	}
 )
@@ -94,6 +122,20 @@ func NewSettleAccountBillDao(tenant string) SettleAccountBillDao {
 			CreateBy:               "CreateBy",
 			CreateOn:               "CreateOn",
 			DeletedAt:              "DeletedAt",
+			MainUserId:             "MainUserId",
+			MainUser:               "MainUser",
+			AccountId:              "AccountId",
+			PaymentDueDate:         "PaymentDueDate",
+			SettlementDateUserId:   "SettlementDateUserId",
+			SettlementDateUser:     "SettlementDateUser",
+			SettlementDate:         "SettlementDate",
+			DeductMoneyUserId:      "DeductMoneyUserId",
+			DeductMoneyUser:        "DeductMoneyUser",
+			DeductMoneyDate:        "DeductMoneyDate",
+			Remark:                 "Remark",
+			UpdateUserId:           "UpdateUserId",
+			UpdateBy:               "UpdateBy",
+			UpdateOn:               "UpdateOn",
 		},
 	}
 	return dao

+ 54 - 9
dao/account/internal/settle_account_detail.go

@@ -26,15 +26,30 @@ type SettleAccountDetailDao struct {
 
 // SettleAccountDetailColumns defines and stores column names for table settle_account_detail.
 type settleAccountDetailColumns struct {
-	Id             string // 主键
-	Pid            string // 结算明细主表Id
-	UnitPrice      string // 计费单价
-	Minutes        string // 计费时长(分钟)
-	PaymentType    string // 支出类型 1正常支出 2违约支出
-	PaymentAccount string // 支出金额
-	CreateUserId   string //
-	CreateBy       string //
-	CreateOn       string //
+	Id              string // 主键
+	Pid             string // 结算明细主表Id
+	UnitPrice       string // 计费单价
+	ActuralMinutes  string // 实际机时(分钟)
+	Minutes         string // 计费时长(分钟)
+	PaymentType     string // 计费类型:0计时收费;1违约收费;2辅助收费
+	PaymentAccount  string // 费用
+	CreateUserId    string //
+	CreateBy        string //
+	CreateOn        string //
+	BillId          string // 账单Id
+	MainUserId      string // 主用户Id
+	MainUser        string // 主用户
+	AttachUserId    string // 从用户Id
+	AttachUser      string // 从用户
+	Data1           string // 备用字段1
+	Data2           string // 备用字段2
+	Data3           string // 备用字段3
+	Data4           string // 备用字段4
+	Data5           string // 备用字段5
+	Remark          string // 备注
+	UpdateUserId    string // 更新者ID
+	UpdateBy        string // 更新者
+	UpdateOn        string // 更新时间
 }
 
 var (
@@ -47,12 +62,27 @@ var (
 			Id:             "Id",
 			Pid:            "pid",
 			UnitPrice:      "UnitPrice",
+			ActuralMinutes: "ActuralMinutes",
 			Minutes:        "Minutes",
 			PaymentType:    "PaymentType",
 			PaymentAccount: "PaymentAccount",
 			CreateUserId:   "CreateUserId",
 			CreateBy:       "CreateBy",
 			CreateOn:       "CreateOn",
+			BillId:         "BillId",
+			MainUserId:     "MainUserId",
+			MainUser:       "MainUser",
+			AttachUserId:   "AttachUserId",
+			AttachUser:     "AttachUser",
+			Data1:          "Data1",
+			Data2:          "Data2",
+			Data3:          "Data3",
+			Data4:          "Data4",
+			Data5:          "Data5",
+			Remark:         "Remark",
+			UpdateUserId:   "UpdateUserId",
+			UpdateBy:       "UpdateBy",
+			UpdateOn:       "UpdateOn",
 		},
 	}
 )
@@ -67,12 +97,27 @@ func NewSettleAccountDetailDao(tenant string) SettleAccountDetailDao {
 			Id:             "Id",
 			Pid:            "pid",
 			UnitPrice:      "UnitPrice",
+			ActuralMinutes: "ActuralMinutes",
 			Minutes:        "Minutes",
 			PaymentType:    "PaymentType",
 			PaymentAccount: "PaymentAccount",
 			CreateUserId:   "CreateUserId",
 			CreateBy:       "CreateBy",
 			CreateOn:       "CreateOn",
+			BillId:         "BillId",
+			MainUserId:     "MainUserId",
+			MainUser:       "MainUser",
+			AttachUserId:   "AttachUserId",
+			AttachUser:     "AttachUser",
+			Data1:          "Data1",
+			Data2:          "Data2",
+			Data3:          "Data3",
+			Data4:          "Data4",
+			Data5:          "Data5",
+			Remark:         "Remark",
+			UpdateUserId:   "UpdateUserId",
+			UpdateBy:       "UpdateBy",
+			UpdateOn:       "UpdateOn",
 		},
 	}
 	return dao

+ 68 - 30
dao/account/internal/settle_account_main.go

@@ -25,21 +25,40 @@ type SettleAccountMainDao struct {
 
 // SettleAccountMainColumns defines and stores column names for table settle_account_main.
 type settleAccountMainColumns struct {
-	Id            string // 主键
-	BillId        string // 账单Id
-	AppointId     string // 预约Id
-	AppointUserId string // 预约人Id
-	AppointUser   string // 预约人
-	MainUserId    string // 主用户Id
-	MainUser      string // 主用户
-	FeeType       string // 费用类型 1机时计费 2样本计费
-	SettleStatus  string // 结算状态 1未确认 2已确认 3已结账
-	TotalPrice    string // 结算总价
-	SettleTime    string // 结算时间
-	CreateUserId  string //
-	CreateBy      string //
-	CreateOn      string //
-	DeletedAt     string // 删除时间
+	Id                 string // 主键
+	BillId             string // 账单Id
+	AppointId          string // 预约Id
+	AppointUserId      string // 预约人Id
+	AppointUser        string // 预约人
+	MainUserId         string // 主用户Id
+	MainUser           string // 主用户
+	FeeType            string // 计费类型:0 机时;
+	SettleStatus       string // 确认状态 0未确认 1已确认
+	TotalPrice         string // 合计费用
+	SettleTime         string // 结算时间
+	CreateUserId       string //
+	CreateBy           string //
+	CreateOn           string //
+	DeletedAt          string // 删除时间
+	AttachUserId       string // 从用户Id
+	AttachUser         string // 从用户
+	Status             string // 账单状态 0未汇总 1已汇总
+	AppointStartDate   string // 预约开始时间
+	AppointEndDate     string // 预约结束时间
+	ActualStartDate    string // 实际上机开始时间
+	ActualEndDate      string // 实际上机结束时间
+	ActualMachineHour  string // 实际机时
+	InstrumentId       string // 仪器Id
+	InstrumentCode     string // 仪器编号
+	InstrumentName     string // 仪器名称
+	SettleUserId       string // 确认人Id
+	SettleUser         string // 确认人
+	SettleDate         string // 确认时间
+	FeeTime            string // 计费时间
+	Remark             string // 备注
+	UpdateUserId       string // 更新者ID
+	UpdateBy           string // 更新者
+	UpdateOn           string // 更新时间
 }
 
 var (
@@ -49,21 +68,40 @@ var (
 		DB:    g.DB("default"),
 		Table: "settle_account_main",
 		Columns: settleAccountMainColumns{
-			Id:            "Id",
-			BillId:        "BillId",
-			AppointId:     "AppointId",
-			AppointUserId: "AppointUserId",
-			AppointUser:   "AppointUser",
-			MainUserId:    "MainUserId",
-			MainUser:      "MainUser",
-			FeeType:       "FeeType",
-			SettleStatus:  "SettleStatus",
-			TotalPrice:    "TotalPrice",
-			SettleTime:    "SettleTime",
-			CreateUserId:  "CreateUserId",
-			CreateBy:      "CreateBy",
-			CreateOn:      "CreateOn",
-			DeletedAt:     "DeletedAt",
+			Id:                "Id",
+			BillId:            "BillId",
+			AppointId:         "AppointId",
+			AppointUserId:     "AppointUserId",
+			AppointUser:       "AppointUser",
+			MainUserId:        "MainUserId",
+			MainUser:          "MainUser",
+			FeeType:           "FeeType",
+			SettleStatus:      "SettleStatus",
+			TotalPrice:        "TotalPrice",
+			SettleTime:        "SettleTime",
+			CreateUserId:      "CreateUserId",
+			CreateBy:          "CreateBy",
+			CreateOn:          "CreateOn",
+			DeletedAt:         "DeletedAt",
+			AttachUserId:      "AttachUserId",
+			AttachUser:        "AttachUser",
+			Status:            "Status",
+			AppointStartDate:  "AppointStartDate",
+			AppointEndDate:    "AppointEndDate",
+			ActualStartDate:   "ActualStartDate",
+			ActualEndDate:     "ActualEndDate",
+			ActualMachineHour: "ActualMachineHour",
+			InstrumentId:      "InstrumentId",
+			InstrumentCode:    "InstrumentCode",
+			InstrumentName:    "InstrumentName",
+			SettleUserId:      "SettleUserId",
+			SettleUser:        "SettleUser",
+			SettleDate:        "SettleDate",
+			FeeTime:           "FeeTime",
+			Remark:            "Remark",
+			UpdateUserId:      "UpdateUserId",
+			UpdateBy:          "UpdateBy",
+			UpdateOn:          "UpdateOn",
 		},
 	}
 )

+ 2 - 2
handler/account.go

@@ -14,7 +14,7 @@ import (
 // 结算
 type Account struct{}
 
-// 结算明细分页
+// 结算明细分页  代码已弃用
 func (a *Account) SettleAccountList(ctx context.Context, req *model.ListReq, rsp *comm_def.CommonMsg) error {
 	tenant, err := micro_srv.GetTenant(ctx)
 	info, err := micro_srv.GetUserInfo(ctx)
@@ -41,7 +41,7 @@ func (a *Account) SettleAccountList(ctx context.Context, req *model.ListReq, rsp
 	return nil
 }
 
-// AddCountMainDetail 添加结算明细主表明细表
+// AddCountMainDetail 添加结算明细主表明细表  代码已弃用
 func (a *Account) AddCountMainDetail(ctx context.Context, req *account.AppointInfoReq, rsp *comm_def.CommonMsg) error {
 	tenant, err := micro_srv.GetTenant(ctx)
 	if err != nil {

+ 1 - 1
model/account/base_account.go

@@ -34,5 +34,5 @@ type AccountReq struct {
 
 type BaseAccountRsp struct {
 	Records []BaseAccountResp `json:"records"`
-	Total   int               `json:"total"'`
+	Total   int               `json:"total"`
 }

+ 30 - 16
model/account/internal/settle_account_bill.go

@@ -10,20 +10,34 @@ import (
 
 // SettleAccountBill is the golang structure for table settle_account_bill.
 type SettleAccountBill struct {
-	Id                     int         `orm:"Id,primary"             json:"id"`                     // 主键
-	Code                   string      `orm:"Code"                   json:"code"`                   // 账单号
-	TotalCount             int         `orm:"TotalCount"             json:"totalCount"`             // 账单总额
-	SettleTime             *gtime.Time `orm:"SettleTime"             json:"settleTime"`             // 结算时间
-	StartDate              *gtime.Time `orm:"StartDate"              json:"startDate"`              // 账单开始时间
-	EndDate                *gtime.Time `orm:"EndDate"                json:"endDate"`                // 账单结束时间
-	Status                 string      `orm:"Status"                 json:"status"`                 // 账单状态  1待确认 2待核销 4已核销
-	ActualVerificationDate *gtime.Time `orm:"ActualVerificationDate" json:"actualVerificationDate"` // 实际核销时间
-	ActualVerificationUser int         `orm:"ActualVerificationUser" json:"actualVerificationUser"` // 实际核销人
-	VerificationUserId     int         `orm:"VerificationUserId"     json:"verificationUserId"`     // 核销人Id
-	VerificationUser       int         `orm:"VerificationUser"       json:"verificationUser"`       // 核销人
-	VerificationDate       *gtime.Time `orm:"VerificationDate"       json:"verificationDate"`       // 完成核销时间
-	CreateUserId           int         `orm:"CreateUserId"           json:"createUserId"`           //
-	CreateBy               string      `orm:"CreateBy"               json:"createBy"`               //
-	CreateOn               *gtime.Time `orm:"CreateOn"               json:"createOn"`               //
-	DeletedAt              *gtime.Time `orm:"DeletedAt"              json:"deletedAt"`              // 删除时间
+	Id                     int         `orm:"Id,primary"             json:"id"`                       // 主键
+	Code                   string      `orm:"Code"                   json:"code"`                     // 账单号
+	TotalCount             float64     `orm:"TotalCount"             json:"total_count"`              // 计费总额
+	SettleTime             *gtime.Time `orm:"SettleTime"             json:"settle_time"`              // 结算时间
+	StartDate              *gtime.Time `orm:"StartDate"              json:"start_date"`               // 账单开始时间
+	EndDate                *gtime.Time `orm:"EndDate"                json:"end_date"`                 // 账单结束时间
+	Status                 string      `orm:"Status"                 json:"status"`                   // 账单状态 0未确认 1已确认 2已结算 3已扣款
+	ActualVerificationDate *gtime.Time `orm:"ActualVerificationDate" json:"actual_verification_date"` // 实际核销时间
+	ActualVerificationUser int         `orm:"ActualVerificationUser" json:"actual_verification_user"` // 实际核销人
+	VerificationUserId     int         `orm:"VerificationUserId"     json:"verification_user_id"`     // 核销人Id
+	VerificationUser       int         `orm:"VerificationUser"       json:"verification_user"`        // 核销人
+	VerificationDate       *gtime.Time `orm:"VerificationDate"       json:"verification_date"`        // 完成核销时间
+	CreateUserId           int         `orm:"CreateUserId"           json:"create_user_id"`           //
+	CreateBy               string      `orm:"CreateBy"               json:"create_by"`                //
+	CreateOn               *gtime.Time `orm:"CreateOn"               json:"create_on"`                //
+	DeletedAt              *gtime.Time `orm:"DeletedAt"              json:"deleted_at"`               // 删除时间
+	MainUserId             int         `orm:"MainUserId"             json:"main_user_id"`             // 主用户Id
+	MainUser               string      `orm:"MainUser"               json:"main_user"`                // 主用户
+	AccountId              int         `orm:"AccountId"              json:"account_id"`               // 经费账号Id
+	PaymentDueDate         *gtime.Time `orm:"PaymentDueDate"         json:"payment_due_date"`         // 付款截止日期
+	SettlementDateUserId   int         `orm:"SettlementDateUserId"   json:"settlement_date_user_id"`  // 结算人Id
+	SettlementDateUser     int         `orm:"SettlementDateUser"     json:"settlement_date_user"`     // 结算人
+	SettlementDate         *gtime.Time `orm:"SettlementDate"         json:"settlement_date"`          // 结算时间
+	DeductMoneyUserId      int         `orm:"DeductMoneyUserId"      json:"deduct_money_user_id"`     // 扣款人Id
+	DeductMoneyUser        int         `orm:"DeductMoneyUser"        json:"deduct_money_user"`        // 扣款人
+	DeductMoneyDate        *gtime.Time `orm:"DeductMoneyDate"        json:"deduct_money_date"`        // 扣款时间
+	Remark                 string      `orm:"Remark"                 json:"remark"`                   // 备注
+	UpdateUserId           int         `orm:"UpdateUserId"           json:"update_user_id"`           // 更新者ID
+	UpdateBy               string      `orm:"UpdateBy"               json:"update_by"`                // 更新者
+	UpdateOn               *gtime.Time `orm:"UpdateOn"               json:"update_on"`                // 更新时间
 }

+ 24 - 8
model/account/internal/settle_account_detail.go

@@ -10,12 +10,28 @@ import (
 
 // SettleAccountDetail is the golang structure for table settle_account_detail.
 type SettleAccountDetail struct {
-	Id             int         `orm:"Id,primary"     json:"id"`             // 主键
-	Pid            int         `orm:"pid"            json:"pid"`            // 结算明细主表Id
-	UnitPrice      int         `orm:"UnitPrice"      json:"unitPrice"`      // 计费单价
-	PaymentType    string      `orm:"PaymentType"    json:"paymentType"`    // 支出类型 1正常支出 2违约支出
-	PaymentAccount string      `orm:"PaymentAccount" json:"paymentAccount"` // 支出金额
-	CreateUserId   int         `orm:"CreateUserId"   json:"createUserId"`   //
-	CreateBy       string      `orm:"CreateBy"       json:"createBy"`       //
-	CreateOn       *gtime.Time `orm:"CreateOn"       json:"createOn"`       //
+	Id             int         `orm:"Id,primary"     json:"id"`              // 主键
+	Pid            int         `orm:"pid"            json:"pid"`             // 结算明细主表Id
+	UnitPrice      float64     `orm:"UnitPrice"      json:"unit_price"`      // 计费单价
+	ActuralMinutes string      `orm:"ActuralMinutes" json:"actural_minutes"` // 实际机时(分钟)
+	Minutes        string      `orm:"Minutes"        json:"minutes"`         // 计费时长(分钟)
+	PaymentType    string      `orm:"PaymentType"    json:"payment_type"`    // 计费类型:0计时收费;1违约收费;2辅助收费
+	PaymentAccount float64     `orm:"PaymentAccount" json:"payment_account"` // 费用
+	CreateUserId   int         `orm:"CreateUserId"   json:"create_user_id"`  //
+	CreateBy       string      `orm:"CreateBy"       json:"create_by"`       //
+	CreateOn       *gtime.Time `orm:"CreateOn"       json:"create_on"`       //
+	BillId         int         `orm:"BillId"         json:"bill_id"`         // 账单Id
+	MainUserId     int         `orm:"MainUserId"     json:"main_user_id"`    // 主用户Id
+	MainUser       string      `orm:"MainUser"       json:"main_user"`       // 主用户
+	AttachUserId   int         `orm:"AttachUserId"   json:"attach_user_id"`  // 从用户Id
+	AttachUser     string      `orm:"AttachUser"     json:"attach_user"`     // 从用户
+	Data1          string      `orm:"Data1"          json:"data_1"`          // 备用字段1
+	Data2          string      `orm:"Data2"          json:"data_2"`          // 备用字段2
+	Data3          string      `orm:"Data3"          json:"data_3"`          // 备用字段3
+	Data4          string      `orm:"Data4"          json:"data_4"`          // 备用字段4
+	Data5          string      `orm:"Data5"          json:"data_5"`          // 备用字段5
+	Remark         string      `orm:"Remark"         json:"remark"`          // 备注
+	UpdateUserId   int         `orm:"UpdateUserId"   json:"update_user_id"`  // 更新者ID
+	UpdateBy       string      `orm:"UpdateBy"       json:"update_by"`       // 更新者
+	UpdateOn       *gtime.Time `orm:"UpdateOn"       json:"update_on"`       // 更新时间
 }

+ 34 - 15
model/account/internal/settle_account_main.go

@@ -10,19 +10,38 @@ import (
 
 // SettleAccountMain is the golang structure for table settle_account_main.
 type SettleAccountMain struct {
-	Id            int         `orm:"Id,primary"    json:"id"`            // 主键
-	BillId        int         `orm:"BillId"        json:"billId"`        // 账单Id
-	AppointId     int         `orm:"AppointId"     json:"appointId"`     // 预约Id
-	AppointUserId int         `orm:"AppointUserId" json:"appointUserId"` // 预约人Id
-	AppointUser   string      `orm:"AppointUser"   json:"appointUser"`   // 预约人
-	MainUserId    int         `orm:"MainUserId"    json:"mainUserId"`    // 主用户Id
-	MainUser      string      `orm:"MainUser"      json:"mainUser"`      // 主用户
-	FeeType       string      `orm:"FeeType"       json:"feeType"`       // 费用类型 1机时计费 2样本计费
-	SettleStatus  string      `orm:"SettleStatus"  json:"settleStatus"`  // 结算状态 1未确认 2已确认 3已结账
-	TotalPrice    int         `orm:"TotalPrice"    json:"totalPrice"`    // 结算总价
-	SettleTime    *gtime.Time `orm:"SettleTime"    json:"settleTime"`    // 结算时间
-	CreateUserId  int         `orm:"CreateUserId"  json:"createUserId"`  //
-	CreateBy      string      `orm:"CreateBy"      json:"createBy"`      //
-	CreateOn      *gtime.Time `orm:"CreateOn"      json:"createOn"`      //
-	DeletedAt     *gtime.Time `orm:"DeletedAt"     json:"deletedAt"`     // 删除时间
+	Id                int         `orm:"Id,primary"        json:"id"`                  // 主键
+	BillId            int         `orm:"BillId"            json:"bill_id"`             // 账单Id
+	AppointId         int         `orm:"AppointId"         json:"appoint_id"`          // 预约Id
+	AppointUserId     int         `orm:"AppointUserId"     json:"appoint_user_id"`     // 预约人Id
+	AppointUser       string      `orm:"AppointUser"       json:"appoint_user"`        // 预约人
+	MainUserId        int         `orm:"MainUserId"        json:"main_user_id"`        // 主用户Id
+	MainUser          string      `orm:"MainUser"          json:"main_user"`           // 主用户
+	FeeType           string      `orm:"FeeType"           json:"fee_type"`            // 计费类型:0 机时;
+	SettleStatus      string      `orm:"SettleStatus"      json:"settle_status"`       // 确认状态 0未确认 1已确认
+	TotalPrice        float64     `orm:"TotalPrice"        json:"total_price"`         // 合计费用
+	SettleTime        *gtime.Time `orm:"SettleTime"        json:"settle_time"`         // 结算时间
+	CreateUserId      int         `orm:"CreateUserId"      json:"create_user_id"`      //
+	CreateBy          string      `orm:"CreateBy"          json:"create_by"`           //
+	CreateOn          *gtime.Time `orm:"CreateOn"          json:"create_on"`           //
+	DeletedAt         *gtime.Time `orm:"DeletedAt"         json:"deleted_at"`          // 删除时间
+	AttachUserId      int         `orm:"AttachUserId"      json:"attach_user_id"`      // 从用户Id
+	AttachUser        string      `orm:"AttachUser"        json:"attach_user"`         // 从用户
+	Status            string      `orm:"Status"            json:"status"`              // 账单状态 0未汇总 1已汇总
+	AppointStartDate  *gtime.Time `orm:"AppointStartDate"  json:"appoint_start_date"`  // 预约开始时间
+	AppointEndDate    *gtime.Time `orm:"AppointEndDate"    json:"appoint_end_date"`    // 预约结束时间
+	ActualStartDate   *gtime.Time `orm:"ActualStartDate"   json:"actual_start_date"`   // 实际上机开始时间
+	ActualEndDate     *gtime.Time `orm:"ActualEndDate"     json:"actual_end_date"`     // 实际上机结束时间
+	ActualMachineHour int         `orm:"ActualMachineHour" json:"actual_machine_hour"` // 实际机时
+	InstrumentId      int         `orm:"InstrumentId"      json:"instrument_id"`       // 仪器Id
+	InstrumentCode    string      `orm:"InstrumentCode"    json:"instrument_code"`     // 仪器编号
+	InstrumentName    string      `orm:"InstrumentName"    json:"instrument_name"`     // 仪器名称
+	SettleUserId      int         `orm:"SettleUserId"      json:"settle_user_id"`      // 确认人Id
+	SettleUser        int         `orm:"SettleUser"        json:"settle_user"`         // 确认人
+	SettleDate        *gtime.Time `orm:"SettleDate"        json:"settle_date"`         // 确认时间
+	FeeTime           *gtime.Time `orm:"FeeTime"           json:"fee_time"`            // 计费时间
+	Remark            string      `orm:"Remark"            json:"remark"`              // 备注
+	UpdateUserId      int         `orm:"UpdateUserId"      json:"update_user_id"`      // 更新者ID
+	UpdateBy          string      `orm:"UpdateBy"          json:"update_by"`           // 更新者
+	UpdateOn          *gtime.Time `orm:"UpdateOn"          json:"update_on"`           // 更新时间
 }

+ 8 - 0
model/account/settle_account_bill.go

@@ -12,3 +12,11 @@ import (
 type SettleAccountBill internal.SettleAccountBill
 
 // Fill with you ideas below.
+
+type SettleAccountBillReq struct {
+	PageNun     int    `json:"pageNum"`
+	PageSize    int    `json:"pageSize"`
+	Account     string `json:"account"`
+	AccountName string `json:"accountName"`
+	RealName    string `json:"realName"`
+}

+ 8 - 0
model/account/settle_account_detail.go

@@ -62,3 +62,11 @@ type SearchUser struct {
 	DepartmentName string `orm:"DepartmentName"        json:"department_name"`
 	IsPreferential string `                            json:"isPreferential"` // 是否享有设备预约优惠 3有优惠
 }
+
+type SettleAccountDetailReq struct {
+	PageNun     int    `json:"pageNum"`
+	PageSize    int    `json:"pageSize"`
+	Account     string `json:"account"`
+	AccountName string `json:"accountName"`
+	RealName    string `json:"realName"`
+}

+ 3 - 1
model/account/settle_account_main.go

@@ -14,6 +14,8 @@ type SettleAccountMain internal2.SettleAccountMain
 // Fill with you ideas below.
 
 type SettleAccountMainReq struct {
+	PageNun     int    `json:"pageNum"`
+	PageSize    int    `json:"pageSize"`
 	AppointUserId int `orm:"AppointUserId"           json:"appoint_user_id"`
 	RelevanceId   int `orm:"RelevanceId"             json:"relevance_id"`
-}
+}

+ 2 - 2
service/account/account.go

@@ -33,7 +33,7 @@ func NewAccountSrv(tenant string) AccountService {
 	return AccountService{Dao: dao.NewBaseAccountDao(tenant), Tenant: tenant}
 }
 
-// 结算明细分页
+// 结算明细分页  代码已弃用
 func (s Service) SettleAccountList(req model.ListReq, info request.UserInfo) ([]account.SettleAccountMain, int, error) {
 	entityModel := s.Dao.DB.Model("settle_account_main s").
 		LeftJoin("appointment a", "s.AppointId = a.Id").
@@ -67,7 +67,7 @@ func (s Service) SettleAccountList(req model.ListReq, info request.UserInfo) ([]
 	return list, total, nil
 }
 
-// 新增结算明细主表、明细子表
+// 新增结算明细主表、明细子表  代码已弃用
 func (s Service) AddCountMainDetail(mobAppoint account.AppointInfoReq) error {
 	contractBreach := 1.0
 	paymentType := 1