| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393 |
- // Code generated by MockGen. DO NOT EDIT.
- // Source: internal/model/perm/sysPermModel.go
- //
- // Generated by this command:
- //
- // mockgen -source=internal/model/perm/sysPermModel.go -destination=internal/testutil/mocks/mock_perm_model.go -package=mocks
- //
- // Package mocks is a generated GoMock package.
- package mocks
- import (
- context "context"
- sql "database/sql"
- perm "perms-system-server/internal/model/perm"
- reflect "reflect"
- sqlx "github.com/zeromicro/go-zero/core/stores/sqlx"
- gomock "go.uber.org/mock/gomock"
- )
- // MockSysPermModel is a mock of SysPermModel interface.
- type MockSysPermModel struct {
- ctrl *gomock.Controller
- recorder *MockSysPermModelMockRecorder
- isgomock struct{}
- }
- // MockSysPermModelMockRecorder is the mock recorder for MockSysPermModel.
- type MockSysPermModelMockRecorder struct {
- mock *MockSysPermModel
- }
- // NewMockSysPermModel creates a new mock instance.
- func NewMockSysPermModel(ctrl *gomock.Controller) *MockSysPermModel {
- mock := &MockSysPermModel{ctrl: ctrl}
- mock.recorder = &MockSysPermModelMockRecorder{mock}
- return mock
- }
- // EXPECT returns an object that allows the caller to indicate expected use.
- func (m *MockSysPermModel) EXPECT() *MockSysPermModelMockRecorder {
- return m.recorder
- }
- // BatchDelete mocks base method.
- func (m *MockSysPermModel) BatchDelete(ctx context.Context, ids []int64) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchDelete", ctx, ids)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchDelete indicates an expected call of BatchDelete.
- func (mr *MockSysPermModelMockRecorder) BatchDelete(ctx, ids any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchDelete", reflect.TypeOf((*MockSysPermModel)(nil).BatchDelete), ctx, ids)
- }
- // BatchDeleteWithTx mocks base method.
- func (m *MockSysPermModel) BatchDeleteWithTx(ctx context.Context, session sqlx.Session, ids []int64) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchDeleteWithTx", ctx, session, ids)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchDeleteWithTx indicates an expected call of BatchDeleteWithTx.
- func (mr *MockSysPermModelMockRecorder) BatchDeleteWithTx(ctx, session, ids any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchDeleteWithTx", reflect.TypeOf((*MockSysPermModel)(nil).BatchDeleteWithTx), ctx, session, ids)
- }
- // BatchInsert mocks base method.
- func (m *MockSysPermModel) BatchInsert(ctx context.Context, dataList []*perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchInsert", ctx, dataList)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchInsert indicates an expected call of BatchInsert.
- func (mr *MockSysPermModelMockRecorder) BatchInsert(ctx, dataList any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchInsert", reflect.TypeOf((*MockSysPermModel)(nil).BatchInsert), ctx, dataList)
- }
- // BatchInsertWithTx mocks base method.
- func (m *MockSysPermModel) BatchInsertWithTx(ctx context.Context, session sqlx.Session, dataList []*perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchInsertWithTx", ctx, session, dataList)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchInsertWithTx indicates an expected call of BatchInsertWithTx.
- func (mr *MockSysPermModelMockRecorder) BatchInsertWithTx(ctx, session, dataList any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchInsertWithTx", reflect.TypeOf((*MockSysPermModel)(nil).BatchInsertWithTx), ctx, session, dataList)
- }
- // BatchUpdate mocks base method.
- func (m *MockSysPermModel) BatchUpdate(ctx context.Context, dataList []*perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchUpdate", ctx, dataList)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchUpdate indicates an expected call of BatchUpdate.
- func (mr *MockSysPermModelMockRecorder) BatchUpdate(ctx, dataList any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchUpdate", reflect.TypeOf((*MockSysPermModel)(nil).BatchUpdate), ctx, dataList)
- }
- // BatchUpdateWithTx mocks base method.
- func (m *MockSysPermModel) BatchUpdateWithTx(ctx context.Context, session sqlx.Session, dataList []*perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "BatchUpdateWithTx", ctx, session, dataList)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // BatchUpdateWithTx indicates an expected call of BatchUpdateWithTx.
- func (mr *MockSysPermModelMockRecorder) BatchUpdateWithTx(ctx, session, dataList any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchUpdateWithTx", reflect.TypeOf((*MockSysPermModel)(nil).BatchUpdateWithTx), ctx, session, dataList)
- }
- // Delete mocks base method.
- func (m *MockSysPermModel) Delete(ctx context.Context, id int64) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "Delete", ctx, id)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // Delete indicates an expected call of Delete.
- func (mr *MockSysPermModelMockRecorder) Delete(ctx, id any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockSysPermModel)(nil).Delete), ctx, id)
- }
- // DeleteWithTx mocks base method.
- func (m *MockSysPermModel) DeleteWithTx(ctx context.Context, session sqlx.Session, id int64) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "DeleteWithTx", ctx, session, id)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // DeleteWithTx indicates an expected call of DeleteWithTx.
- func (mr *MockSysPermModelMockRecorder) DeleteWithTx(ctx, session, id any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteWithTx", reflect.TypeOf((*MockSysPermModel)(nil).DeleteWithTx), ctx, session, id)
- }
- // DisableNotInCodesWithTx mocks base method.
- func (m *MockSysPermModel) DisableNotInCodesWithTx(ctx context.Context, session sqlx.Session, productCode string, codes []string, now int64) (int64, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "DisableNotInCodesWithTx", ctx, session, productCode, codes, now)
- ret0, _ := ret[0].(int64)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // DisableNotInCodesWithTx indicates an expected call of DisableNotInCodesWithTx.
- func (mr *MockSysPermModelMockRecorder) DisableNotInCodesWithTx(ctx, session, productCode, codes, now any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DisableNotInCodesWithTx", reflect.TypeOf((*MockSysPermModel)(nil).DisableNotInCodesWithTx), ctx, session, productCode, codes, now)
- }
- // FindAllCodesByProductCode mocks base method.
- func (m *MockSysPermModel) FindAllCodesByProductCode(ctx context.Context, productCode string) ([]string, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindAllCodesByProductCode", ctx, productCode)
- ret0, _ := ret[0].([]string)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindAllCodesByProductCode indicates an expected call of FindAllCodesByProductCode.
- func (mr *MockSysPermModelMockRecorder) FindAllCodesByProductCode(ctx, productCode any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindAllCodesByProductCode", reflect.TypeOf((*MockSysPermModel)(nil).FindAllCodesByProductCode), ctx, productCode)
- }
- // FindByIds mocks base method.
- func (m *MockSysPermModel) FindByIds(ctx context.Context, ids []int64) ([]*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindByIds", ctx, ids)
- ret0, _ := ret[0].([]*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindByIds indicates an expected call of FindByIds.
- func (mr *MockSysPermModelMockRecorder) FindByIds(ctx, ids any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindByIds", reflect.TypeOf((*MockSysPermModel)(nil).FindByIds), ctx, ids)
- }
- // FindListByProductCode mocks base method.
- func (m *MockSysPermModel) FindListByProductCode(ctx context.Context, productCode string, page, pageSize int64) ([]*perm.SysPerm, int64, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindListByProductCode", ctx, productCode, page, pageSize)
- ret0, _ := ret[0].([]*perm.SysPerm)
- ret1, _ := ret[1].(int64)
- ret2, _ := ret[2].(error)
- return ret0, ret1, ret2
- }
- // FindListByProductCode indicates an expected call of FindListByProductCode.
- func (mr *MockSysPermModelMockRecorder) FindListByProductCode(ctx, productCode, page, pageSize any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindListByProductCode", reflect.TypeOf((*MockSysPermModel)(nil).FindListByProductCode), ctx, productCode, page, pageSize)
- }
- // FindMapByProductCode mocks base method.
- func (m *MockSysPermModel) FindMapByProductCode(ctx context.Context, productCode string) (map[string]*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindMapByProductCode", ctx, productCode)
- ret0, _ := ret[0].(map[string]*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindMapByProductCode indicates an expected call of FindMapByProductCode.
- func (mr *MockSysPermModelMockRecorder) FindMapByProductCode(ctx, productCode any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindMapByProductCode", reflect.TypeOf((*MockSysPermModel)(nil).FindMapByProductCode), ctx, productCode)
- }
- // FindMapByProductCodeWithTx mocks base method.
- func (m *MockSysPermModel) FindMapByProductCodeWithTx(ctx context.Context, session sqlx.Session, productCode string) (map[string]*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindMapByProductCodeWithTx", ctx, session, productCode)
- ret0, _ := ret[0].(map[string]*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindMapByProductCodeWithTx indicates an expected call of FindMapByProductCodeWithTx.
- func (mr *MockSysPermModelMockRecorder) FindMapByProductCodeWithTx(ctx, session, productCode any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindMapByProductCodeWithTx", reflect.TypeOf((*MockSysPermModel)(nil).FindMapByProductCodeWithTx), ctx, session, productCode)
- }
- // FindOne mocks base method.
- func (m *MockSysPermModel) FindOne(ctx context.Context, id int64) (*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindOne", ctx, id)
- ret0, _ := ret[0].(*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindOne indicates an expected call of FindOne.
- func (mr *MockSysPermModelMockRecorder) FindOne(ctx, id any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOne", reflect.TypeOf((*MockSysPermModel)(nil).FindOne), ctx, id)
- }
- // FindOneByProductCodeCode mocks base method.
- func (m *MockSysPermModel) FindOneByProductCodeCode(ctx context.Context, productCode, code string) (*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindOneByProductCodeCode", ctx, productCode, code)
- ret0, _ := ret[0].(*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindOneByProductCodeCode indicates an expected call of FindOneByProductCodeCode.
- func (mr *MockSysPermModelMockRecorder) FindOneByProductCodeCode(ctx, productCode, code any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOneByProductCodeCode", reflect.TypeOf((*MockSysPermModel)(nil).FindOneByProductCodeCode), ctx, productCode, code)
- }
- // FindOneByProductCodeCodeWithTx mocks base method.
- func (m *MockSysPermModel) FindOneByProductCodeCodeWithTx(ctx context.Context, session sqlx.Session, productCode, code string) (*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindOneByProductCodeCodeWithTx", ctx, session, productCode, code)
- ret0, _ := ret[0].(*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindOneByProductCodeCodeWithTx indicates an expected call of FindOneByProductCodeCodeWithTx.
- func (mr *MockSysPermModelMockRecorder) FindOneByProductCodeCodeWithTx(ctx, session, productCode, code any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOneByProductCodeCodeWithTx", reflect.TypeOf((*MockSysPermModel)(nil).FindOneByProductCodeCodeWithTx), ctx, session, productCode, code)
- }
- // FindOneWithTx mocks base method.
- func (m *MockSysPermModel) FindOneWithTx(ctx context.Context, session sqlx.Session, id int64) (*perm.SysPerm, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "FindOneWithTx", ctx, session, id)
- ret0, _ := ret[0].(*perm.SysPerm)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // FindOneWithTx indicates an expected call of FindOneWithTx.
- func (mr *MockSysPermModelMockRecorder) FindOneWithTx(ctx, session, id any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOneWithTx", reflect.TypeOf((*MockSysPermModel)(nil).FindOneWithTx), ctx, session, id)
- }
- // Insert mocks base method.
- func (m *MockSysPermModel) Insert(ctx context.Context, data *perm.SysPerm) (sql.Result, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "Insert", ctx, data)
- ret0, _ := ret[0].(sql.Result)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // Insert indicates an expected call of Insert.
- func (mr *MockSysPermModelMockRecorder) Insert(ctx, data any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Insert", reflect.TypeOf((*MockSysPermModel)(nil).Insert), ctx, data)
- }
- // InsertWithTx mocks base method.
- func (m *MockSysPermModel) InsertWithTx(ctx context.Context, session sqlx.Session, data *perm.SysPerm) (sql.Result, error) {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "InsertWithTx", ctx, session, data)
- ret0, _ := ret[0].(sql.Result)
- ret1, _ := ret[1].(error)
- return ret0, ret1
- }
- // InsertWithTx indicates an expected call of InsertWithTx.
- func (mr *MockSysPermModelMockRecorder) InsertWithTx(ctx, session, data any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InsertWithTx", reflect.TypeOf((*MockSysPermModel)(nil).InsertWithTx), ctx, session, data)
- }
- // TableName mocks base method.
- func (m *MockSysPermModel) TableName() string {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "TableName")
- ret0, _ := ret[0].(string)
- return ret0
- }
- // TableName indicates an expected call of TableName.
- func (mr *MockSysPermModelMockRecorder) TableName() *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TableName", reflect.TypeOf((*MockSysPermModel)(nil).TableName))
- }
- // TransactCtx mocks base method.
- func (m *MockSysPermModel) TransactCtx(ctx context.Context, fn func(context.Context, sqlx.Session) error) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "TransactCtx", ctx, fn)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // TransactCtx indicates an expected call of TransactCtx.
- func (mr *MockSysPermModelMockRecorder) TransactCtx(ctx, fn any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TransactCtx", reflect.TypeOf((*MockSysPermModel)(nil).TransactCtx), ctx, fn)
- }
- // Update mocks base method.
- func (m *MockSysPermModel) Update(ctx context.Context, data *perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "Update", ctx, data)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // Update indicates an expected call of Update.
- func (mr *MockSysPermModelMockRecorder) Update(ctx, data any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockSysPermModel)(nil).Update), ctx, data)
- }
- // UpdateWithTx mocks base method.
- func (m *MockSysPermModel) UpdateWithTx(ctx context.Context, session sqlx.Session, data *perm.SysPerm) error {
- m.ctrl.T.Helper()
- ret := m.ctrl.Call(m, "UpdateWithTx", ctx, session, data)
- ret0, _ := ret[0].(error)
- return ret0
- }
- // UpdateWithTx indicates an expected call of UpdateWithTx.
- func (mr *MockSysPermModelMockRecorder) UpdateWithTx(ctx, session, data any) *gomock.Call {
- mr.mock.ctrl.T.Helper()
- return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateWithTx", reflect.TypeOf((*MockSysPermModel)(nil).UpdateWithTx), ctx, session, data)
- }
|