diff --git a/Dockerfile b/Dockerfile index 5c3b886..3f96c7d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM golang:alpine as builder -WORKDIR /go/src/github.com/flipped-aurora/gin-vue-admin/server +WORKDIR /go/src/gin_server_admin COPY . . RUN go env -w GO111MODULE=on @@ -13,9 +13,9 @@ RUN go build -o server . FROM alpine:latest LABEL MAINTAINER="SliverHorn@sliver_horn@qq.com" -WORKDIR /go/src/github.com/flipped-aurora/gin-vue-admin/server +WORKDIR /go/src/gin_server_admin -COPY --from=0 /go/src/github.com/flipped-aurora/gin-vue-admin/server ./ +COPY --from=0 /go/src/gin_server_admin ./ EXPOSE 8888 diff --git a/README.md b/README.md index 717f240..c5130b4 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ ├── timer └── upload ``` -## 文件说明 +## 文件说明 module gin_server_admin | 文件夹 | 说明 | 描述 | | ------------ | ----------------------- | --------------------------- | diff --git a/api/admin/dutyassess/assess.go b/api/admin/dutyassess/assess.go index 40ac514..a4eeb77 100644 --- a/api/admin/dutyassess/assess.go +++ b/api/admin/dutyassess/assess.go @@ -7,13 +7,13 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/assessment" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/examtestpage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/api/v1/assessment" + "gin_server_admin/api/v1/examtestpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/admin/dutyassess/assesstype.go b/api/admin/dutyassess/assesstype.go index 77c3643..d96f7f1 100644 --- a/api/admin/dutyassess/assesstype.go +++ b/api/admin/dutyassess/assesstype.go @@ -3,30 +3,30 @@ package dutyassess import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/assessmentmodel" ) type DutyAssessApi struct{} -//协程设置 +// 协程设置 var syncProcess = sync.WaitGroup{} -//数据锁统计 +// 数据锁统计 type dataLockStatistics struct { dataMap []map[string]interface{} dataErrMap []map[string]interface{} mutext sync.RWMutex } -//读取锁数据 +// 读取锁数据 func (d *dataLockStatistics) readMyDayData() ([]map[string]interface{}, []map[string]interface{}) { d.mutext.RLock() defer d.mutext.RUnlock() return d.dataMap, d.dataErrMap } -//获取部门考核列表 +// 获取部门考核列表 type getDepartAssObtain struct { commonus.PageSetLimt DepartID string `json:"depart"` //部门Id @@ -38,12 +38,12 @@ type getDepartAssObtains struct { Time string `json:"time"` //查询日期 } -//获取集团分厂 +// 获取集团分厂 type getGroupDepart struct { Id []int64 } -//部门月份具体考核详情 +// 部门月份具体考核详情 type departMonth struct { Id int64 `json:"id"` Title string `json:"title"` @@ -62,12 +62,12 @@ type departDutyList struct { DutyTitle string `json:"dutyTitle"` } -//归档审批人 +// 归档审批人 type commentUser struct { UserKey int64 `json:"userkey" gorm:"column:s_comment_user;type:bigint(20) unsigned;default:0;not null;comment:评论人"` } -//输出考核关系架构 +// 输出考核关系架构 type outAessDuty struct { ClassId int64 `json:"classId"` ClassTitle string `json:"classTitle"` @@ -76,7 +76,7 @@ type outAessDuty struct { DutyTitle string `json:"dutyTitle"` } -//具体职责项与考核项目,类别 +// 具体职责项与考核项目,类别 type dutyAssClass struct { Title string `json:"title" gorm:"column:dc_title;type:text;comment:具体职责"` PartId int64 `json:"partId" gorm:"column:dc_parent;type:bigint(20) unsigned;default:0;not null;comment:父级"` @@ -85,7 +85,7 @@ type dutyAssClass struct { ClassTitle string `json:"Classtitle" gorm:"column:title;type:varchar(255);comment:职责类别名称"` } -//部门月份考核列表 +// 部门月份考核列表 type departMonthMap struct { DepartId int64 `json:"departId"` //部门ID DepartTitle string `json:"departTitle"` //部门名称 @@ -93,7 +93,7 @@ type departMonthMap struct { DateStr string `json:"datestr"` //日期字符串 } -//定量考核目标设定查询 +// 定量考核目标设定查询 type SelectQuantitativeConfig struct { GroupId string `json:"groupid"` DepartmentID string `json:"departmentid"` @@ -107,7 +107,7 @@ type SelectQuantitativeConfig struct { Title string `json:"title"` //指标标题 } -//输出 +// 输出 type OutQuantitativeConfig struct { assessmentmodel.QuantitativeConfig GroupTitle string `json:"grouptitle"` //操作组 @@ -117,13 +117,13 @@ type OutQuantitativeConfig struct { DetailedTargetTitle string `json:"detailedtargenttitle"` //指标明细 } -//输出定性指标列表 +// 输出定性指标列表 type DutySelectList struct { assessmentmodel.EvaluationTarget DepartmentList []string } -//考核方案细则列表输出 +// 考核方案细则列表输出 type TargetContOutCont struct { Id string `json:"id"` Type int `json:"type"` @@ -167,7 +167,7 @@ type TargetContOutCont struct { } -//定性考核列表输出 +// 定性考核列表输出 type QualEvalArrt struct { Id string `json:"id"` Name string `json:"name"` @@ -179,7 +179,7 @@ type QualEvalArrt struct { Operator []string `json:"operator"` //操作人 } -//输出定性考核列表 +// 输出定性考核列表 type OutDutyList struct { Id string `json:"id"` Target string `json:"target"` //指标ID @@ -202,7 +202,7 @@ type DepartmentAryType struct { Parentname string `json:"parentname"` } -//输出定性考核列表 +// 输出定性考核列表 type OutDutyListes struct { Id string `json:"id"` Target string `json:"target"` //指标ID @@ -222,7 +222,7 @@ type OutDutyListes struct { Group string `json:"group"` } -//根据指标ID获取相关信息 +// 根据指标ID获取相关信息 type TargetFormId struct { OutDutyList SunTargetList []SunTargetListType `json:"sunlist"` @@ -239,7 +239,7 @@ type DetailedTargetType struct { UserListAry []QualEvalArrt `json:"userlistary"` //执行人列表 } -//获取定性指标->指标细则修改回显 +// 获取定性指标->指标细则修改回显 type OutTargetCont struct { Id string `json:"id"` SunTargerId string `json:"suntargetid"` @@ -260,7 +260,7 @@ type OutTargetCont struct { DepartmentId []string `json:"departmentid"` //接受考核的部门 } -//获取定性指标->指标细则修改回显修改或新增 +// 获取定性指标->指标细则修改回显修改或新增 type GetEiteTargetCont struct { Id string `json:"id"` Class int `json:"class"` //1、新增;2、修改 @@ -278,7 +278,7 @@ type GetEiteTargetCont struct { DepartmentId []string `json:"departmentid"` //接受考核的部门 } -//添加 定性考核指标关系指定 +// 添加 定性考核指标关系指定 type AddQualEval struct { AcceptDepartmentId []string `json:"parentid"` //接受考核部门 Dimension string `json:"dimension"` //考核维度 @@ -291,7 +291,7 @@ type AddQualEval struct { EvaluationList []QualEvalSunList `json:"evaluationlist"` //测评详情 } -//定性考核内容 +// 定性考核内容 type QualEvalSunList struct { DetailedTarget string `json:"id"` //考核细则 Title string `json:"title"` //指标说明 @@ -311,14 +311,14 @@ type QualEvalSunList struct { CensorRate int `json:"censorrate"` //检查频次 } -//添加 定性考核指标关系指定细则 +// 添加 定性考核指标关系指定细则 type DutyAssEssTarget struct { Id int64 `json:"id"` Operator []string `json:"operator"` //考核执行人 Department []string `json:"department"` //部门 } -//查看定性指标详情列表 +// 查看定性指标详情列表 type LookTargetContList struct { Group string `json:"group"` //归属集团 TargetId string `json:"targetid"` @@ -330,13 +330,13 @@ type LookTargetContList struct { CensorRate int `json:"censorrate"` //检查频次 } -//查看定性指标细则提交参数 +// 查看定性指标细则提交参数 type GetDeitalTarCont struct { Id string `json:"id"` AssId string `json:"assid"` } -//输出新版指标明细列表 +// 输出新版指标明细列表 type NewOutPutDetailedTarget struct { OutTargetCont Unit string `json:"unit"` //单位 @@ -345,7 +345,6 @@ type NewOutPutDetailedTarget struct { AddReduce int `json:"addreduce"` //1:减少;2:增加;3:无属性,现场确认加或减 } -// type NewEiteDtyDiteCont struct { GetEiteTargetCont AssId string `json:"assid"` @@ -354,13 +353,13 @@ type NewEiteDtyDiteCont struct { AddOrReduce int `json:"addreduce"` //1:减少;2:增加 } -//定量考核列表查询 +// 定量考核列表查询 type rationSelect struct { Group string `json:"group"` //归属集团 DepartmentId string `json:"parentid"` //接受考核部门 } -//部门考核指标组合列表输出 +// 部门考核指标组合列表输出 type DepartTargetListTop struct { Id string `json:"id"` Name string `json:"name"` @@ -376,7 +375,7 @@ type DepartTargetList struct { IsTrue int `json:"istrue"` //是否允许修改 } -//添加部门考核项目新 +// 添加部门考核项目新 type AddDutyNewContGroup struct { Group string `json:"group"` //集团 DepartmentId string `json:"parentid"` //部门 @@ -391,7 +390,7 @@ type AddDutyNewCont struct { Child []EvaluPross `json:"child"` //考核细则 } -//指标 +// 指标 type EvaluPross struct { Id string `json:"id"` //维度ID Name string `json:"name"` @@ -406,7 +405,7 @@ type EvaluPross struct { Status int `json:"status"` //1:使用;2:禁用;3:观察 } -//添加部门考核过度 +// 添加部门考核过度 type AddPartMentGuodu struct { Group int64 `json:"group"` //集团 DeaprtId int64 `json:"deaprtid"` //部门ID @@ -417,7 +416,7 @@ type AddPartMentGuodu struct { Operator []string `json:"operator"` //操作人 } -//删除部门指标考核获取参数 +// 删除部门指标考核获取参数 type DelDutyDepartTarget struct { Group string `json:"group"` //归属集团 DeaprtId string `json:"deaprtid"` //部门ID @@ -425,13 +424,13 @@ type DelDutyDepartTarget struct { Dimension string `json:"dimension"` //考核维度 } -//修改已知定性考核指标关联部门 +// 修改已知定性考核指标关联部门 type EiteDutyForDepart struct { LookTargetContList DepartAry []string `json:"departary"` } -//考核方案版本列表查询 +// 考核方案版本列表查询 type DutyPlanVersio struct { Group string `json:"group"` //归属集团 DeaprtId string `json:"deaprtid"` //部门ID @@ -441,13 +440,13 @@ type DutyPlanVersio struct { State int `json:"state"` //状态 } -//岗位考核方案版本列表查询 +// 岗位考核方案版本列表查询 type positionPlanVersio struct { DutyPlanVersio Position string `json:"position"` //岗位 } -//考核方案版本列表查询输出 +// 考核方案版本列表查询输出 type DutyPlanVersioOut struct { assessmentmodel.PlanVersio GroupName string `json:"groupname"` //归属集团 @@ -463,19 +462,19 @@ type positionPlanVersionOut struct { Time string `json:"time"` } -//查看考核方案详情 +// 查看考核方案详情 type LookDutyVersio struct { Key string `json:"key"` } -//更改状态 +// 更改状态 type SetOnOffDutyVersio struct { LookDutyVersio IsTrue int `json:"istrue"` //强制删除 State int `json:"state"` //状态 } -//并发输出 +// 并发输出 type bingFaOut struct { Id int64 `json:"id" gorm:"primaryKey;column:sf_id;type:bigint(20) unsigned;not null;comment:Id"` Key int64 `json:"key" gorm:"column:sf_key;type:bigint(20) unsigned;default:0;not null;comment:识别标志"` @@ -493,7 +492,7 @@ type bingFaOutDingLiang struct { State int `json:"state" gorm:"column:ep_state;type:int(2) unsigned;default:1;not null;comment:1:审批,2:通过;3:驳回;"` } -//修改部门考核方案说明 +// 修改部门考核方案说明 type EitrDepartExplan struct { Group string `json:"group"` //集团 DeaprtId string `json:"deaprtid"` //部门ID @@ -507,13 +506,12 @@ type EitrDepartExplan struct { State int `json:"state"` } -//获取 +// 获取 type LookTargetContListSun struct { LookTargetContList SunTargetId string `json:"suntargetid"` //子栏目 } -// type EiteTargetContListSun struct { Id string `json:"id"` Name string `json:"name"` @@ -530,14 +528,14 @@ type EiteTargetContListSun struct { CensorRate int `json:"censorrate"` //检查频次 } -//定性考核列表 +// 定性考核列表 type dutyList struct { Group int64 `json:"group" gorm:"column:group;type:bigint(20) unsigned;default:0;not null;comment:集团ID"` TargetId int64 `json:"targetid" gorm:"column:targetid;type:bigint(20) unsigned;default:0;not null;comment:指标"` SunTargetId int64 `json:"suntargetid" gorm:"column:suntargetid;type:bigint(20) unsigned;default:0;not null;comment:子栏目ID"` } -//定性考核方案新输出 +// 定性考核方案新输出 type dutyOutNew struct { Group string `json:"group"` Dimension string `json:"dimension"` //维度ID @@ -552,7 +550,7 @@ type dutyOutNew struct { CycleAttres int `json:"cycleattr"` //辅助计数"` } -//查看定性考核列表新型输出 +// 查看定性考核列表新型输出 type scanDutyOutList struct { Id string `json:"id"` Group string `json:"group"` @@ -576,7 +574,7 @@ type scanDutyOutList struct { DepartNameMap []string `json:"departnamemap"` //子栏目部门 } -//部门版本新考核方案输出 +// 部门版本新考核方案输出 type departPlanDutyOut struct { Id string `json:"id"` //指标ID、 Qualevalid string `json:"qualevalid"` //版本号码 @@ -614,7 +612,7 @@ type CopyDutyNewCont struct { Child []CopyEvaluPross `json:"child"` //考核细则 } -//指标 +// 指标 type CopyEvaluPross struct { Id string `json:"id"` //维度ID Name string `json:"name"` @@ -625,7 +623,7 @@ type CopyEvaluPross struct { Istrue int `json:"istrue"` //是否允许修改 } -//修改考核目标设定 +// 修改考核目标设定 type EiteQuantConfig struct { Id string `json:"id"` Zeroprize float64 `json:"zeroprize"` //零奖值"` @@ -633,7 +631,7 @@ type EiteQuantConfig struct { Capping float64 `json:"capping"` //封顶值"` } -//删除考核目标设定 +// 删除考核目标设定 type DelQuantConfig struct { Id string `json:"id"` } diff --git a/api/admin/dutyassess/dutyes.go b/api/admin/dutyassess/dutyes.go index 5222d74..ec6afb1 100644 --- a/api/admin/dutyassess/dutyes.go +++ b/api/admin/dutyassess/dutyes.go @@ -7,10 +7,10 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" "github.com/mitchellh/mapstructure" ) diff --git a/api/admin/dutyassess/dutyhandle.go b/api/admin/dutyassess/dutyhandle.go index d349dd4..263cfb3 100644 --- a/api/admin/dutyassess/dutyhandle.go +++ b/api/admin/dutyassess/dutyhandle.go @@ -7,10 +7,10 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/admin/dutyassess/planversio.go b/api/admin/dutyassess/planversio.go index fdadb05..c256e44 100644 --- a/api/admin/dutyassess/planversio.go +++ b/api/admin/dutyassess/planversio.go @@ -7,10 +7,10 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/admin/dutyassess/position.go b/api/admin/dutyassess/position.go index 1822c92..276bc8e 100644 --- a/api/admin/dutyassess/position.go +++ b/api/admin/dutyassess/position.go @@ -1,14 +1,14 @@ package dutyassess import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) -//岗位考核方案列表 +// 岗位考核方案列表 func (d *DutyAssessApi) PositionDepartPlanVersion(c *gin.Context) { var requestData positionPlanVersio err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/enter.go b/api/admin/enter.go index 6a42800..9c0b5bc 100644 --- a/api/admin/enter.go +++ b/api/admin/enter.go @@ -1,9 +1,9 @@ package admin import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/admin/dutyassess" - "github.com/flipped-aurora/gin-vue-admin/server/api/admin/groupmanagement" - "github.com/flipped-aurora/gin-vue-admin/server/api/admin/systemuser" + "gin_server_admin/api/admin/dutyassess" + "gin_server_admin/api/admin/groupmanagement" + "gin_server_admin/api/admin/systemuser" ) type ApiGroup struct { diff --git a/api/admin/groupmanagement/branchfactorygroup/branchfactory.go b/api/admin/groupmanagement/branchfactorygroup/branchfactory.go index f73c341..c817900 100644 --- a/api/admin/groupmanagement/branchfactorygroup/branchfactory.go +++ b/api/admin/groupmanagement/branchfactorygroup/branchfactory.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) @@ -22,7 +22,7 @@ func (b *BranchFactory) Index(c *gin.Context) { response.Result(0, outPut, "分厂基础设定获取成功", c) } -//获取分厂栏目 +// 获取分厂栏目 func (b *BranchFactory) BranchFactoryList(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -93,7 +93,7 @@ func (b *BranchFactory) BranchFactoryList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加分厂 +// 添加分厂 func (b *BranchFactory) AddBranchFactory(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -152,7 +152,7 @@ func (b *BranchFactory) AddBranchFactory(c *gin.Context) { } } -//获取分厂(部室)详细信息 +// 获取分厂(部室)详细信息 func (b *BranchFactory) GetBranchFactory(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -179,7 +179,7 @@ func (b *BranchFactory) GetBranchFactory(c *gin.Context) { response.Result(0, systemBFCont, "数据获取成功!", c) } -//修改分厂内容 +// 修改分厂内容 func (b *BranchFactory) EiteBranchFactory(c *gin.Context) { var requestData EiteBranchFactory err := c.ShouldBindJSON(&requestData) @@ -242,7 +242,7 @@ func (b *BranchFactory) EiteBranchFactory(c *gin.Context) { } } -//编辑分厂数据处理 +// 编辑分厂数据处理 func eiteBranchFactoryInfo(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Master.Model(&testpage.BranchFactory{}).Where("`bf_id` = ?", saveId).Updates(saveData).Error @@ -253,7 +253,7 @@ func eiteBranchFactoryInfo(saveId int64, saveData map[string]interface{}) (isTru return } -//删除分厂内容 +// 删除分厂内容 func (b *BranchFactory) DelBranchFactory(c *gin.Context) { var requestData delBFType err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/groupmanagement/branchfactorygroup/duties.go b/api/admin/groupmanagement/branchfactorygroup/duties.go index 0171603..e9f8a3f 100644 --- a/api/admin/groupmanagement/branchfactorygroup/duties.go +++ b/api/admin/groupmanagement/branchfactorygroup/duties.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) @@ -20,7 +20,7 @@ func (d *DutiesApi) Index(c *gin.Context) { response.Result(0, outPut, "职务基础设定入口", c) } -//职务列表 +// 职务列表 func (d *DutiesApi) DutiesList(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -95,7 +95,7 @@ func (d *DutiesApi) DutiesList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取职务信息 +// 获取职务信息 func (w *DutiesApi) GetDutiesCont(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -122,7 +122,7 @@ func (w *DutiesApi) GetDutiesCont(c *gin.Context) { response.Result(0, systemBFCont, "数据获取成功!", c) } -//添加职务 +// 添加职务 func (w *DutiesApi) AddDutiesCont(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -189,7 +189,7 @@ func (w *DutiesApi) AddDutiesCont(c *gin.Context) { } } -//编辑职务数据处理 +// 编辑职务数据处理 func eiteDutiesInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Master.Model(&testpage.Position{}).Where("`ps_id` = ?", saveId).Updates(saveData).Error @@ -200,7 +200,7 @@ func eiteDutiesInfoes(saveId int64, saveData map[string]interface{}) (isTrue boo return } -//编辑职务数据 +// 编辑职务数据 func (w *DutiesApi) EiteDutiesCont(c *gin.Context) { var requestData EiteDutiesInfo err := c.ShouldBindJSON(&requestData) @@ -267,7 +267,7 @@ func (w *DutiesApi) EiteDutiesCont(c *gin.Context) { } } -//删除工段内容 +// 删除工段内容 func (w *DutiesApi) DelDutiesCont(c *gin.Context) { var requestData delBFType err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/groupmanagement/branchfactorygroup/team.go b/api/admin/groupmanagement/branchfactorygroup/team.go index da5bfbf..d6c8457 100644 --- a/api/admin/groupmanagement/branchfactorygroup/team.go +++ b/api/admin/groupmanagement/branchfactorygroup/team.go @@ -4,20 +4,20 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (t *TeamApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "班组基础设定入口", c) } -//获取班组列表 +// 获取班组列表 func (t *TeamApi) TeamApiList(c *gin.Context) { var requestData TeamList c.ShouldBindJSON(&requestData) @@ -40,7 +40,7 @@ func (t *TeamApi) TeamApiList(c *gin.Context) { response.Result(0, systemRoleList, "数据获取成功!", c) } -//获取班组详细内容 +// 获取班组详细内容 func (t *TeamApi) GetTeamContApi(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -67,7 +67,7 @@ func (t *TeamApi) GetTeamContApi(c *gin.Context) { response.Result(0, systemBFCont, "数据获取成功!", c) } -//添加班组 +// 添加班组 func (t *TeamApi) AddTeamContApi(c *gin.Context) { var requestData AddTeam err := c.ShouldBindJSON(&requestData) @@ -102,7 +102,7 @@ func (t *TeamApi) AddTeamContApi(c *gin.Context) { } } -//编辑班组数据处理 +// 编辑班组数据处理 func eiteTeamInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Master.Model(&testpage.Teaming{}).Where("`tm_id` = ?", saveId).Updates(saveData).Error @@ -113,7 +113,7 @@ func eiteTeamInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, return } -//修改班组 +// 修改班组 func (t *TeamApi) EiteTeamContApi(c *gin.Context) { var requestData EiteTeam err := c.ShouldBindJSON(&requestData) @@ -166,7 +166,7 @@ func (t *TeamApi) EiteTeamContApi(c *gin.Context) { } } -//删除版主内容 +// 删除版主内容 func (w *TeamApi) DelTeamCont(c *gin.Context) { var requestData delBFType err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/groupmanagement/branchfactorygroup/type.go b/api/admin/groupmanagement/branchfactorygroup/type.go index 5e93a83..af44d93 100644 --- a/api/admin/groupmanagement/branchfactorygroup/type.go +++ b/api/admin/groupmanagement/branchfactorygroup/type.go @@ -1,11 +1,11 @@ package branchfactorygroup import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/model/testpage" ) -//分厂 +// 分厂 type BranchFactory struct{} type BranchFactoryList struct { commonus.PageSetLimt @@ -15,13 +15,13 @@ type BranchFactoryList struct { Title string `json:"title"` } -//分厂列表输出 +// 分厂列表输出 type PrintBranchFactoryList struct { testpage.BranchFactory GroupName string `json:"groupname"` } -//创建分厂 +// 创建分厂 type AddBranchFactory struct { Title string `json:"title"` GroupId int64 `json:"groupid"` @@ -29,23 +29,23 @@ type AddBranchFactory struct { Attribute int64 `json:"attribute"` } -//修改分厂信息 +// 修改分厂信息 type EiteBranchFactory struct { commonus.SetIds AddBranchFactory } -//删除分厂信息 +// 删除分厂信息 type delBFType struct { commonus.SetIds State int `json:"state"` // 状态 IsDel int `json:"isdel"` // 是否强制删除 } -//工段 +// 工段 type WorkshopSectionApi struct{} -//工段列表 +// 工段列表 type WorKSectionList struct { commonus.PageSetLimt GroupId int64 `json:"groupid"` @@ -54,20 +54,20 @@ type WorKSectionList struct { Title string `json:"title"` } -//工段列表输出 +// 工段列表输出 type WorKSectionListPrint struct { testpage.WorkShopsection GroupName string `json:"groupname"` BranchFactoryName string `json:"branchfactoryname"` } -//添加工段 +// 添加工段 type AddWorkSectionInfo struct { Title string `json:"title"` BranchFactoryId int64 `json:"branchfactoryid"` } -//编辑工段内容 +// 编辑工段内容 type EiteWorkSectionInfo struct { commonus.SetIds AddWorkSectionInfo @@ -79,14 +79,14 @@ type EiteWorkSectionInfo struct { type DutiesApi struct{} -//添加职务 +// 添加职务 type AddDutiesInfo struct { AddWorkSectionInfo Weight int64 `json:"weight"` Genexa int64 `json:"genexa"` } -//编辑职务 +// 编辑职务 type EiteDutiesInfo struct { commonus.SetIds AddDutiesInfo @@ -97,20 +97,20 @@ type EiteDutiesInfo struct { */ type TeamApi struct{} -//班组列表 +// 班组列表 type TeamList struct { State int `json:"state"` Title string `json:"title"` Shifts int `json:"shifts"` } -//添加班组数据录入 +// 添加班组数据录入 type AddTeam struct { Title string `json:"title"` Shifts int64 `json:"shifts"` } -//修改班组数据录入 +// 修改班组数据录入 type EiteTeam struct { commonus.SetIds AddTeam diff --git a/api/admin/groupmanagement/branchfactorygroup/workshopsection.go b/api/admin/groupmanagement/branchfactorygroup/workshopsection.go index 08100cf..c95688b 100644 --- a/api/admin/groupmanagement/branchfactorygroup/workshopsection.go +++ b/api/admin/groupmanagement/branchfactorygroup/workshopsection.go @@ -4,20 +4,20 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (w *WorkshopSectionApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "工段基础设定入口", c) } -//工段列表 +// 工段列表 func (w *WorkshopSectionApi) WorKSection(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -92,7 +92,7 @@ func (w *WorkshopSectionApi) WorKSection(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加工段 +// 添加工段 func (w *WorkshopSectionApi) AddWorkSectionCont(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -148,7 +148,7 @@ func (w *WorkshopSectionApi) AddWorkSectionCont(c *gin.Context) { } } -//获取工段信息 +// 获取工段信息 func (w *WorkshopSectionApi) GetWorkSectionCont(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -175,7 +175,7 @@ func (w *WorkshopSectionApi) GetWorkSectionCont(c *gin.Context) { response.Result(0, systemBFCont, "数据获取成功!", c) } -//修改工段内容 +// 修改工段内容 func (w *WorkshopSectionApi) EiteWorkSectionCont(c *gin.Context) { var requestData EiteWorkSectionInfo err := c.ShouldBindJSON(&requestData) @@ -236,7 +236,7 @@ func (w *WorkshopSectionApi) EiteWorkSectionCont(c *gin.Context) { } } -//编辑工段数据处理 +// 编辑工段数据处理 func eiteWorkSectionInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Master.Model(&testpage.WorkShopsection{}).Where("`ws_id` = ?", saveId).Updates(saveData).Error @@ -247,7 +247,7 @@ func eiteWorkSectionInfoes(saveId int64, saveData map[string]interface{}) (isTru return } -//删除工段内容 +// 删除工段内容 func (w *WorkshopSectionApi) DelWorkSection(c *gin.Context) { var requestData delBFType err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/groupmanagement/enter.go b/api/admin/groupmanagement/enter.go index 46c7fda..75d5234 100644 --- a/api/admin/groupmanagement/enter.go +++ b/api/admin/groupmanagement/enter.go @@ -1,6 +1,6 @@ package groupmanagement -import "github.com/flipped-aurora/gin-vue-admin/server/api/admin/groupmanagement/branchfactorygroup" +import "gin_server_admin/api/admin/groupmanagement/branchfactorygroup" type ApiGroup struct { BranchFactoryApi branchfactorygroup.ApiGroup diff --git a/api/admin/systemuser/adminrole.go b/api/admin/systemuser/adminrole.go index 0284604..6aa142e 100644 --- a/api/admin/systemuser/adminrole.go +++ b/api/admin/systemuser/adminrole.go @@ -5,15 +5,15 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/systemuser" "github.com/gin-gonic/gin" ) -//角色相关 -//入口 +// 角色相关 +// 入口 func (s *SystemRoleApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "角色管理入口获取成功", c) @@ -105,7 +105,7 @@ func (s *SystemRoleApi) SystemRoleList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取角色详细内容 +// 获取角色详细内容 func GetAdminRoleInfo(id int64) (isTrue bool, adminRoleInfo systemuser.SystemRole) { isTrue = false err := global.GVA_DB_Master.Where("r_id = ?", id).First(&adminRoleInfo).Error @@ -115,7 +115,7 @@ func GetAdminRoleInfo(id int64) (isTrue bool, adminRoleInfo systemuser.SystemRol return } -//添加系统角色 +// 添加系统角色 func (s *SystemRoleApi) AddSystemRole(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -191,7 +191,7 @@ func (s *SystemRoleApi) AddSystemRole(c *gin.Context) { } } -//修改系统角色 +// 修改系统角色 func (s *SystemRoleApi) EiteSystemRole(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -260,7 +260,7 @@ func (s *SystemRoleApi) EiteSystemRole(c *gin.Context) { } } -//删除系统角色 +// 删除系统角色 func (s *SystemRoleApi) DelSystemRole(c *gin.Context) { var requestData delSystemRoleType @@ -311,7 +311,7 @@ func (s *SystemRoleApi) DelSystemRole(c *gin.Context) { } } -//获取系统角色详情 +// 获取系统角色详情 func (s *SystemRoleApi) GetSystemRole(c *gin.Context) { var requestData commonus.SetId @@ -372,7 +372,7 @@ func (s *SystemRoleApi) GetSystemRole(c *gin.Context) { response.Result(0, printRoleCont, "数据获取成功!", c) } -//编辑角色数据处理 +// 编辑角色数据处理 func eiteSystemRoleCont(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Master.Model(&systemuser.SystemRole{}).Where("`r_id` = ?", saveId).Updates(saveData).Error @@ -383,7 +383,7 @@ func eiteSystemRoleCont(saveId int64, saveData map[string]interface{}) (isTrue b return } -//获取角色权限配置清单 +// 获取角色权限配置清单 func (s *SystemRoleApi) GetPowerConfig(c *gin.Context) { var requestData commonus.SetId err := c.ShouldBindJSON(&requestData) @@ -411,7 +411,7 @@ func (s *SystemRoleApi) GetPowerConfig(c *gin.Context) { response.Result(0, datahhh, "数据获取失败!", c) } -//遍历确权 +// 遍历确权 func GetMenuOperation(menuStr, menuOperStr string) (isTrue bool, sendData []powerConfigList) { isTrue = false var menuStrMap []string @@ -430,7 +430,7 @@ func GetMenuOperation(menuStr, menuOperStr string) (isTrue bool, sendData []powe return } -//递归无限树 +// 递归无限树 func GetMenuPowerThree(jurisd int, parentId int64, threeData []systemuser.SystemMenu, menuStrMap, menuOperStrMap []string) []powerConfigList { // treeList := []SystemMenuThree{} treeListPower := []powerConfigList{} @@ -461,7 +461,7 @@ func GetMenuPowerThree(jurisd int, parentId int64, threeData []systemuser.System return treeListPower } -//判断值是否在数组中 +// 判断值是否在数组中 func JudeInArray(id int64, ary []string) (isTrue bool) { isTrue = false for _, val := range ary { @@ -475,7 +475,7 @@ func JudeInArray(id int64, ary []string) (isTrue bool) { return } -//配置角色权限 +// 配置角色权限 func (s *SystemRoleApi) SetPowerConfig(c *gin.Context) { var requestData SetPowerCont err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/systemuser/menutype.go b/api/admin/systemuser/menutype.go index 7bb01aa..172bd0e 100644 --- a/api/admin/systemuser/menutype.go +++ b/api/admin/systemuser/menutype.go @@ -1,17 +1,17 @@ package systemuser import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" + "gin_server_admin/commonus" + "gin_server_admin/model/systemuser" ) -//查询角色列表 +// 查询角色列表 type menuList struct { commonus.PageSetLimt Title string `json:"title"` } -//输出角色列表 +// 输出角色列表 type printRoleList struct { systemuser.SystemRole GroupName string `json:"groupname"` @@ -20,20 +20,20 @@ type printRoleList struct { MenuoperPower []string `json:"jmenuoperpower"` } -//添加角色获取数据 +// 添加角色获取数据 type addSystemRoleType struct { Name string `json:"name"` //角色名称 Group int `json:"group"` //顶级归属 GroupSun int `json:"groupsun"` //次级归属 } -//修改系统角色 +// 修改系统角色 type eiteSystemRoleType struct { commonus.SetIds addSystemRoleType } -//删除角色 +// 删除角色 type delSystemRoleType struct { commonus.SetIds State int `json:"state"` // 状态 @@ -50,19 +50,19 @@ type powerCont struct { IsTrue bool `json:"istrue"` } -//权限树 +// 权限树 type powerConfigList struct { powerCont Child []powerConfigList `json:"child"` MenuOperation []powerCont `json:"menuOperation"` } -//ID映射用 +// ID映射用 type powerStrToInt struct { val int64 `json:"val"` } -//获取配置权限参数 +// 获取配置权限参数 type SetPowerCont struct { commonus.SetIds Menu string `json:"menu"` diff --git a/api/admin/systemuser/systemmenu.go b/api/admin/systemuser/systemmenu.go index 8201bdb..d9df69e 100644 --- a/api/admin/systemuser/systemmenu.go +++ b/api/admin/systemuser/systemmenu.go @@ -4,14 +4,14 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/systemuser" "github.com/gin-gonic/gin" ) -//菜单相关 +// 菜单相关 func (s *SysTemMenuApi) SystemMenuList(c *gin.Context) { // response.Result(101, global.Gva_Authority_Authentication, "数据获取失败!", c) var systemMenuList []systemuser.SystemMenu @@ -26,7 +26,7 @@ func (s *SysTemMenuApi) SystemMenuList(c *gin.Context) { response.Result(0, sendData, "数据获取成功!", c) } -//递归无限树 +// 递归无限树 func GetMenuThree(jurisd int, parentId int64, threeData []systemuser.SystemMenu) []SystemMenuThree { treeList := []SystemMenuThree{} for _, v := range threeData { @@ -54,7 +54,7 @@ func GetMenuThree(jurisd int, parentId int64, threeData []systemuser.SystemMenu) return treeList } -//获取菜单操作项目 +// 获取菜单操作项目 func MenuOperation(jurisd int, menuId int64) (isTrue bool, operation []systemuser.MenuOperation) { isTrue = false if jurisd != 1 { @@ -71,7 +71,7 @@ func MenuOperation(jurisd int, menuId int64) (isTrue bool, operation []systemuse return } -//获取左侧菜单栏 +// 获取左侧菜单栏 func (s *SysTemMenuApi) GetMenu(c *gin.Context) { var systemMenuList []systemuser.SystemMenu menuOperErr := global.GVA_DB_Master.Where("`m_steat` IN ? AND m_id IN ?", []int{1, 2}, global.Gva_Authority_Authentication_Subsidiary).Order("m_id desc").Find(&systemMenuList).Error @@ -85,7 +85,7 @@ func (s *SysTemMenuApi) GetMenu(c *gin.Context) { response.Result(0, sendData, "数据获取成功!", c) } -//菜单列表(不带操作) +// 菜单列表(不带操作) func (s *SysTemMenuApi) GetMenuList(c *gin.Context) { var systemMenuList []systemuser.SystemMenu menuOperErr := global.GVA_DB_Master.Where("`m_steat` IN ? AND `m_parent` = 0", []int{1, 2}).Order("m_sort asc").Order("m_id desc").Find(&systemMenuList).Error @@ -99,7 +99,7 @@ func (s *SysTemMenuApi) GetMenuList(c *gin.Context) { response.Result(0, sendData, "数据获取成功!", c) } -//添加菜单 +// 添加菜单 func (s *SysTemMenuApi) AddMenu(c *gin.Context) { // isTrue, userCont := commonus.AdminClientIdentity() isTrue, userCont := commonus.ClientIdentity() @@ -160,7 +160,7 @@ func (s *SysTemMenuApi) AddMenu(c *gin.Context) { } } -//修改菜单 +// 修改菜单 func (s *SysTemMenuApi) EiteMenu(c *gin.Context) { // isTrue, _ := commonus.AdminClientIdentity() isTrue, _ := commonus.ClientIdentity() @@ -222,14 +222,14 @@ func (s *SysTemMenuApi) EiteMenu(c *gin.Context) { response.Result(0, saveData, "修改成功!", c) } -//菜单编辑操作 +// 菜单编辑操作 func eiteAssEssInfoCont(saveId int64, saveData map[string]interface{}) (menuErr error) { var menuCont systemuser.SystemMenu menuErr = global.GVA_DB_Master.Model(&menuCont).Where("m_id = ?", saveId).Updates(saveData).Error return } -//菜单删除 +// 菜单删除 func (s *SysTemMenuApi) DelMenu(c *gin.Context) { // isTrue, _ := commonus.AdminClientIdentity() isTrue, _ := commonus.ClientIdentity() @@ -286,7 +286,7 @@ func (s *SysTemMenuApi) DelMenu(c *gin.Context) { } } -//添加菜单操作 +// 添加菜单操作 func (s *SysTemMenuApi) AddMenuOperation(c *gin.Context) { // isTrue, _ := commonus.AdminClientIdentity() isTrue, _ := commonus.ClientIdentity() @@ -333,7 +333,7 @@ func (s *SysTemMenuApi) AddMenuOperation(c *gin.Context) { } } -//删除菜单操作 +// 删除菜单操作 func (s *SysTemMenuApi) DelMenuOperation(c *gin.Context) { // isTrue, _ := commonus.AdminClientIdentity() isTrue, _ := commonus.ClientIdentity() diff --git a/api/admin/systemuser/userhandle.go b/api/admin/systemuser/userhandle.go index 7ca82e3..d562fdf 100644 --- a/api/admin/systemuser/userhandle.go +++ b/api/admin/systemuser/userhandle.go @@ -4,22 +4,22 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/systemuser" + "gin_server_admin/model/testpage" + "gin_server_admin/model/wechat" "github.com/gin-gonic/gin" ) -//系统相关 +// 系统相关 func (s *SystemUserApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "获取成功", c) } -//管理员列表 +// 管理员列表 func (s *SystemUserApi) AdminList(c *gin.Context) { var requestData adminRequest c.ShouldBindJSON(&requestData) @@ -118,7 +118,7 @@ func (s *SystemUserApi) AdminList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取管理员详细内容登录 +// 获取管理员详细内容登录 func GetSysAdminLoginInfo(userName, userPwd string) (isTrue bool, sysAdminInfo adminOutInfo) { isTrue = false var md5JiaMi commonus.Md5Encryption @@ -176,7 +176,7 @@ func GetSysAdminLoginInfo(userName, userPwd string) (isTrue bool, sysAdminInfo a return } -//获取管理员分组列表 +// 获取管理员分组列表 func (s *SystemUserApi) SystemAdminGroupList(c *gin.Context) { isTrue, SysAdminCont := commonus.AdminClientIdentity() if isTrue != true { @@ -231,7 +231,7 @@ func (s *SystemUserApi) SystemAdminGroupList(c *gin.Context) { response.Result(0, systemAdminGroup, "查询成功!", c) } -//根据具体获取分厂结构及管理角色 +// 根据具体获取分厂结构及管理角色 func groupBfRole(groupId int64) (isTrue bool, bfRoleAry []SystemAdminGroup) { isTrue = false var branchFactory []testpage.BranchFactory @@ -254,7 +254,7 @@ func groupBfRole(groupId int64) (isTrue bool, bfRoleAry []SystemAdminGroup) { return } -//获取分厂角色 +// 获取分厂角色 func GetBfRole(bfId int64) (isTrue bool, bfRoleAry []SystemAdminGroup) { isTrue = false var branchFactory []systemuser.SystemRole @@ -273,7 +273,7 @@ func GetBfRole(bfId int64) (isTrue bool, bfRoleAry []SystemAdminGroup) { return } -//添加系统管理员 +// 添加系统管理员 func (s *SystemUserApi) AddSystemAdmin(c *gin.Context) { var requestData AddSysAdmin err := c.ShouldBindJSON(&requestData) @@ -356,7 +356,7 @@ func (s *SystemUserApi) AddSystemAdmin(c *gin.Context) { } } -//获取管理员信息 +// 获取管理员信息 func (s *SystemUserApi) GetSystemAdminCont(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -428,7 +428,7 @@ func (s *SystemUserApi) GetSystemAdminCont(c *gin.Context) { response.Result(0, sysAdminInfo, "该用户不存在!", c) } -//修改管理员 +// 修改管理员 func (s *SystemUserApi) EiteSystemAdminCont(c *gin.Context) { var requestData EiteSysAdmin err := c.ShouldBindJSON(&requestData) @@ -503,7 +503,7 @@ func (s *SystemUserApi) EiteSystemAdminCont(c *gin.Context) { } } -//编辑系统管理员数据处理 +// 编辑系统管理员数据处理 func eiteSystemAdminCont(saveId int64, saveData, saveDataAttr map[string]interface{}) (isTrue bool, affairDbErr error) { isTrue = false affairDb := global.GVA_DB_Master.Begin() @@ -523,7 +523,7 @@ func eiteSystemAdminCont(saveId int64, saveData, saveDataAttr map[string]interfa return } -//删除系统管理员 +// 删除系统管理员 func (s *SystemUserApi) DelSystemAdmin(c *gin.Context) { var requestData delSystemRoleType err := c.ShouldBindJSON(&requestData) diff --git a/api/admin/systemuser/usertype.go b/api/admin/systemuser/usertype.go index 9d8d5c5..9d693a8 100644 --- a/api/admin/systemuser/usertype.go +++ b/api/admin/systemuser/usertype.go @@ -1,13 +1,13 @@ package systemuser import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" + "gin_server_admin/commonus" + "gin_server_admin/model/systemuser" ) type SystemUserApi struct{} -//管理员列表查询 +// 管理员列表查询 type adminRequest struct { commonus.PageSetLimt GroupId int `json:"groupId"` @@ -17,7 +17,7 @@ type adminRequest struct { UserName string `json:"username"` } -//管理员输出 +// 管理员输出 type adminOutInfo struct { systemuser.SystemAdminDetails RoleName string `json:"roleName"` @@ -29,13 +29,13 @@ type adminOutInfo struct { Wand int `json:"wand"` } -//角色相关 +// 角色相关 type SystemRoleApi struct{} -//菜单相关 +// 菜单相关 type SysTemMenuApi struct{} -//菜单递给 +// 菜单递给 type SystemMenuThree struct { Id int64 `json:"id"` Title string `json:"title"` @@ -50,12 +50,12 @@ type SystemMenuThree struct { MenuOperation []systemuser.MenuOperation `json:"menuOperation"` } -//查询菜单列表 +// 查询菜单列表 type getMenuData struct { StateOperation int `json:"stateOperation"` } -//添加菜单参数 +// 添加菜单参数 type addMenuData struct { Title string `json:"title"` ParentId int `json:"parentId"` @@ -63,7 +63,7 @@ type addMenuData struct { Sort int `json:"sort"` } -//修改菜单参数 +// 修改菜单参数 type eiteMenuData struct { Id int `json:"id"` Title string `json:"title"` @@ -72,13 +72,13 @@ type eiteMenuData struct { Sort int `json:"sort"` } -//添加菜单功能操作 +// 添加菜单功能操作 type addMenuOper struct { MenuId string `json:"menuid"` Title string `json:"title"` } -//管理员分组 +// 管理员分组 type SystemAdminGroupSun struct { commonus.SetIds Title string `json:"title"` @@ -88,7 +88,7 @@ type SystemAdminGroup struct { Child []SystemAdminGroup `json:"child"` } -//添加管理员 +// 添加管理员 type AddSysAdmin struct { UserName string `json:"username"` Password string `json:"password"` @@ -99,7 +99,7 @@ type AddSysAdmin struct { Tel string `json:"tel"` } -//编辑管理员 +// 编辑管理员 type EiteSysAdmin struct { commonus.SetIds UserName string `json:"username"` diff --git a/api/index/assessment/assesshandle.go b/api/index/assessment/assesshandle.go index 9a1fdd1..0915136 100644 --- a/api/index/assessment/assesshandle.go +++ b/api/index/assessment/assesshandle.go @@ -6,27 +6,27 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/assessment" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/api/v1/assessment" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/systemuser" + "gin_server_admin/model/testpage" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" "github.com/mitchellh/mapstructure" ) -//考核入口 +// 考核入口 func (a *Assessment) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "用户端获取成功", c) } -//扫码登录回传 +// 扫码登录回传 func (a *Assessment) ScanCode(c *gin.Context) { var requestData scanCodeStr err := c.ShouldBindJSON(&requestData) @@ -117,7 +117,7 @@ func (a *Assessment) ScanCodeOld(c *gin.Context) { response.Result(0, sendData, "用户端获取成功", c) } -//获取要考核的列表 +// 获取要考核的列表 func (a *Assessment) MyAssEssMentList(c *gin.Context) { var requestData getAssEssList err := c.ShouldBindJSON(&requestData) @@ -199,7 +199,7 @@ func (a *Assessment) MyAssEssMentList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获得项目考核部门 +// 获得项目考核部门 func GetAssDepart(dutyid int64, dataStr string) (isTrue bool, assessDepartstr []assessDepart) { isTrue = false var departDuty []assessmentmodel.DepartDuty @@ -230,7 +230,7 @@ func GetAssDepart(dutyid int64, dataStr string) (isTrue bool, assessDepartstr [] return } -//判断部门指定月份是否已经考核完毕 +// 判断部门指定月份是否已经考核完毕 func JudgeResAssEssExam(dutyId, departId int64, monthTimeStr string) (isTrue bool) { isTrue = false // var departscores assessmentmodel.Departscores @@ -248,7 +248,7 @@ func JudgeResAssEssExam(dutyId, departId int64, monthTimeStr string) (isTrue boo return } -//根据具体考核项获取被考核部门 +// 根据具体考核项获取被考核部门 func (a *Assessment) GetDutyDepartList(c *gin.Context) { var requestData assessDepartRequest err := c.ShouldBindJSON(&requestData) @@ -277,7 +277,7 @@ func (a *Assessment) GetDutyDepartList(c *gin.Context) { response.Result(0, outData, "查询成功!", c) } -//添加考核评分 +// 添加考核评分 func (a *Assessment) AddAssessmentScore(c *gin.Context) { var requestData addAssEssScores err := c.ShouldBindJSON(&requestData) @@ -401,7 +401,7 @@ func (a *Assessment) AddAssessmentScore(c *gin.Context) { } } -//我的评价记录 +// 我的评价记录 func (a *Assessment) MyEvaluateList(c *gin.Context) { var requestData usEvaluate err := c.ShouldBindJSON(&requestData) @@ -481,7 +481,7 @@ func (a *Assessment) MyEvaluateList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//根据部门和时间获取考核详情 +// 根据部门和时间获取考核详情 func (a *Assessment) GetDepartTimeAssess(c *gin.Context) { var requestData departTimeAssess err := c.ShouldBindJSON(&requestData) @@ -571,7 +571,7 @@ func (a *Assessment) GetDepartTimeAssess(c *gin.Context) { response.Result(0, outPrint, "获取成功!", c) } -//获取考核项目列表 +// 获取考核项目列表 func GetAssList(classId, depart, timeVal int64) (isTrue bool, departMonthAss []departMonthSun) { isTrue = false var departScorsList []assessmentmodel.Departscores @@ -597,7 +597,7 @@ func GetAssList(classId, depart, timeVal int64) (isTrue bool, departMonthAss []d return } -//获取具体考核项目 +// 获取具体考核项目 func GetDetailedDuty(classId, assId, depart, timeVal int64) (isTrue bool, departMonthUser []departMonthSun) { isTrue = false var departScorsList []commentUser @@ -632,7 +632,7 @@ func GetDetailedDuty(classId, assId, depart, timeVal int64) (isTrue bool, depart return } -//获取考核具体职责项目 +// 获取考核具体职责项目 func GetDutyContAry(classId, assId, depart, userKey, timeVal int64) (isTrue bool, dutyList []departDutyList) { // fmt.Printf("--->%v--->%v\n", classId, assId) isTrue = false @@ -670,7 +670,7 @@ func GetDutyContAry(classId, assId, depart, userKey, timeVal int64) (isTrue bool return } -//获取职责类别内容 +// 获取职责类别内容 func GetDutyInfoCont(id int64) (isTrue bool, outAssDutyInfo outAessDuty) { isTrue = false var ContInfo dutyAssClass @@ -690,7 +690,7 @@ func GetDutyInfoCont(id int64) (isTrue bool, outAssDutyInfo outAessDuty) { return } -//以部门为维度获取考核项目 +// 以部门为维度获取考核项目 func (a *Assessment) DepartmentAssess(c *gin.Context) { var requestData departAssessType err := c.ShouldBindJSON(&requestData) @@ -758,7 +758,7 @@ func (a *Assessment) DepartmentAssess(c *gin.Context) { response.Result(0, outContMap, "查询成功!", c) } -//以部门为基准填写考核数据 +// 以部门为基准填写考核数据 func (a *Assessment) DepartmentAssessData(c *gin.Context) { var requestData DepartDutyData err := c.ShouldBindJSON(&requestData) @@ -949,7 +949,7 @@ func (a *Assessment) DepartmentAssessData(c *gin.Context) { } } -//查看审批详细内容 +// 查看审批详细内容 func (a *Assessment) LookDepartmentAssessInfo(c *gin.Context) { var requestData LookDutyCont err := c.ShouldBindJSON(&requestData) @@ -1031,7 +1031,7 @@ func (a *Assessment) LookDepartmentAssessInfo(c *gin.Context) { response.Result(0, outContMap, "数据写入成功!", c) } -//查询自建应用审批单当前状态 +// 查询自建应用审批单当前状态 func (a *Assessment) LookOpenApprovalDataInfo(c *gin.Context) { var requestData LookDutyCont err := c.ShouldBindJSON(&requestData) @@ -1074,7 +1074,7 @@ func (a *Assessment) LookOpenApprovalDataInfo(c *gin.Context) { response.Result(0, jsonToOpenApprovalStruct, "查询成功!", c) } -//查看本部门提交的和个人提交的审批 +// 查看本部门提交的和个人提交的审批 func (a *Assessment) LookPersonalOrDepartment(c *gin.Context) { var requestData commonus.PageSetLimt err := c.ShouldBindJSON(&requestData) @@ -1153,7 +1153,7 @@ func (a *Assessment) LookPersonalOrDepartment(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取班组列表 +// 获取班组列表 func (a *Assessment) GetTeamList(c *gin.Context) { var teamList []testpage.Teaming err := global.GVA_DB_Master.Order("tm_long ASC,tm_id ASC").Find(&teamList).Error diff --git a/api/index/assessment/assesstype.go b/api/index/assessment/assesstype.go index 55b9b0c..4ce572c 100644 --- a/api/index/assessment/assesstype.go +++ b/api/index/assessment/assesstype.go @@ -3,37 +3,37 @@ package assessment import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/assessmentmodel" ) -//考核 +// 考核 type Assessment struct{} -//协程设置 +// 协程设置 var synergeticProcess = sync.WaitGroup{} -//数据锁统计 +// 数据锁统计 type dataLockStatistics struct { dataMap []map[string]interface{} mutext sync.RWMutex } -//读取锁数据 +// 读取锁数据 func (d *dataLockStatistics) readDataLock() []map[string]interface{} { d.mutext.RLock() defer d.mutext.RUnlock() return d.dataMap } -//列表参数 +// 列表参数 type getAssEssList struct { commonus.PageSetLimt BranchFactoryId int `json:"branchFactoryId"` DayState int `json:"daystate"` } -//考核项目输出 +// 考核项目输出 type assessOut struct { assessmentmodel.DutyContent ClassId int64 `json:"classId"` @@ -44,7 +44,7 @@ type assessOut struct { OutId string `json:"outId"` } -//要考核的部门评分 +// 要考核的部门评分 type assessDepart struct { DepartDutyId int64 `json:"departDutyId"` DepartId int64 `json:"departId"` @@ -57,12 +57,12 @@ type assessDepart struct { IsTrue bool `json:"istrue"` } -//更具具体考核项目获取考核部门 +// 更具具体考核项目获取考核部门 type assessDepartRequest struct { Id string `json:"id"` } -//添加考核评分 +// 添加考核评分 type addAssEssScore struct { ClassId string `json:"classID"` //考核分类 AssessId string `json:"assessId"` //考核项目 @@ -90,13 +90,13 @@ type addAssEssScores struct { CommentUser string `json:"commentUser"` //评论人 } -//获取部门时间考核详情 +// 获取部门时间考核详情 type departTimeAssess struct { DepartId int64 `json:"departId"` Time string `json:"time"` } -//查询个人评价列表 +// 查询个人评价列表 type usEvaluate struct { commonus.PageSetLimt departTimeAssess @@ -109,14 +109,14 @@ type usEvaluateOutList struct { Score int `json:"sumscore" gorm:"column:sumscore;type:int(3) unsigned;default:0;not null;comment:实际得分"` } -//个人评价列表输出 +// 个人评价列表输出 type usEvaluateOut struct { usEvaluateOutList FileTimeStr string `json:"timeStr"` DepartTitle string `json:"departTitle"` } -//部门月份考核详细输出 +// 部门月份考核详细输出 type departDataAssess struct { assessmentmodel.Departscores FileTimeStr string `json:"timeStr"` @@ -124,7 +124,7 @@ type departDataAssess struct { outAessDuty } -//输出考核关系架构 +// 输出考核关系架构 type outAessDuty struct { ClassId int64 `json:"classId"` ClassTitle string `json:"classTitle"` @@ -133,7 +133,7 @@ type outAessDuty struct { DutyTitle string `json:"dutyTitle"` } -//具体职责项与考核项目,类别 +// 具体职责项与考核项目,类别 type dutyAssClass struct { Title string `json:"title" gorm:"column:dc_title;type:text;comment:具体职责"` PartId int64 `json:"partId" gorm:"column:dc_parent;type:bigint(20) unsigned;default:0;not null;comment:父级"` @@ -142,7 +142,7 @@ type dutyAssClass struct { ClassTitle string `json:"Classtitle" gorm:"column:title;type:varchar(255);comment:职责类别名称"` } -//部门月份具体考核详情 +// 部门月份具体考核详情 type departMonth struct { Id int64 `json:"id"` Title string `json:"title"` @@ -161,19 +161,19 @@ type departDutyList struct { DutyTitle string `json:"dutyTitle"` } -//归档审批人 +// 归档审批人 type commentUser struct { UserKey int64 `json:"userkey" gorm:"column:s_comment_user;type:bigint(20) unsigned;default:0;not null;comment:评论人"` } -//部门维度考核 +// 部门维度考核 type departAssessType struct { DepartmentId int `json:"departmentid"` GroupId int `json:"groupid"` DayState int `json:"daystate"` } -//查询输出 +// 查询输出 type departAssessOutType struct { assessmentmodel.DepartDuty Titles string `json:"titles" gorm:"column:dc_title;type:text;comment:具体职责"` @@ -187,7 +187,7 @@ type departAssessOutType struct { OutID string `json:"outid"` } -//以部门为单位提报数据 +// 以部门为单位提报数据 type DepartDutyData struct { OrderId string `json:"orderid"` //订单ID Title string `json:"title"` //标题 @@ -198,7 +198,7 @@ type DepartDutyData struct { DutyList []DutyListType `json:"dutylist"` //考核细则 } -//考核细则数据 +// 考核细则数据 type DutyListType struct { DutyId string `json:"dutyid"` //职责ID DeductPoints int `json:"deductpoints"` //扣分 @@ -208,12 +208,12 @@ type DutyListType struct { ExtraPointsText string `json:"extrapointstext"` //加分说明 } -//查看提交审批的详细内容 +// 查看提交审批的详细内容 type LookDutyCont struct { Id string `json:"id"` } -//查看提交审批的详细内容结果 +// 查看提交审批的详细内容结果 type OpenApprovalDataInfo struct { Errcode int `json:"errcode"` Errmsg string `json:"errmsg"` @@ -267,13 +267,13 @@ type NotifyNodeType struct { ItemUserId string `json:"ItemUserId"` } -//查看本部门提交的和个人提交的审批 +// 查看本部门提交的和个人提交的审批 type PersonalOrDepartment struct { assessmentmodel.AssessmentLog AssdepartTitle string `json:"assdeparttitle"` //被考核部门 } -//查看审批考核详细 +// 查看审批考核详细 type LookSeeDutyCont struct { Id string `json:"id"` ClassID string `json:"classID"` @@ -291,7 +291,7 @@ type LookSeeDutyCont struct { ExtraPointstext string `json:"extraPointstext"` } -//扫码登录回传 +// 扫码登录回传 type scanCodeStr struct { UserKey string `json:"userkey"` UserToken string `json:"usertoken"` diff --git a/api/index/enter.go b/api/index/enter.go index 321ac1c..ec26163 100644 --- a/api/index/enter.go +++ b/api/index/enter.go @@ -1,10 +1,10 @@ package index import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/index/assessment" - "github.com/flipped-aurora/gin-vue-admin/server/api/index/evaluation" - "github.com/flipped-aurora/gin-vue-admin/server/api/index/examineandapprove" - "github.com/flipped-aurora/gin-vue-admin/server/api/index/statistics" + "gin_server_admin/api/index/assessment" + "gin_server_admin/api/index/evaluation" + "gin_server_admin/api/index/examineandapprove" + "gin_server_admin/api/index/statistics" ) type ApiGroup struct { diff --git a/api/index/evaluation/assessment.go b/api/index/evaluation/assessment.go index 68347e1..6219a9e 100644 --- a/api/index/evaluation/assessment.go +++ b/api/index/evaluation/assessment.go @@ -5,14 +5,14 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//新定性考核列表 +// 新定性考核列表 func (e *EvaluationInterface) NewQualitative(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -79,7 +79,7 @@ func (e *EvaluationInterface) NewQualitative(c *gin.Context) { response.Result(0, outContList, "获取成功!", c) } -//获取定性考核详细指标 +// 获取定性考核详细指标 func (e *EvaluationInterface) NewGetQualDetailedTarget(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -169,7 +169,7 @@ func (e *EvaluationInterface) NewGetQualDetailedTarget(c *gin.Context) { response.Result(0, outContList, "获取成功!", c) } -//判断全奖与零奖参数 +// 判断全奖与零奖参数 func AllZreoConfig(cycles int) (monthInt int64) { switch cycles { case 4: @@ -186,7 +186,7 @@ func AllZreoConfig(cycles int) (monthInt int64) { return } -//获取定量考核任务列表===>筛出已经提交的数据 +// 获取定量考核任务列表===>筛出已经提交的数据 func (e *EvaluationInterface) QualitativeEvalRationNew(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/index/evaluation/enter.go b/api/index/evaluation/enter.go index 0c1356f..8abad1d 100644 --- a/api/index/evaluation/enter.go +++ b/api/index/evaluation/enter.go @@ -3,12 +3,12 @@ package evaluation import ( "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) -//数据评估 +// 数据评估 type ApiGroup struct { EvaluationApi EvaluationInterface } diff --git a/api/index/evaluation/evaluation.go b/api/index/evaluation/evaluation.go index 2abe786..cf7d06b 100644 --- a/api/index/evaluation/evaluation.go +++ b/api/index/evaluation/evaluation.go @@ -7,22 +7,22 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//个人要执行的考核任务 +// 个人要执行的考核任务 func (e *EvaluationInterface) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "用户端个人要执行的考核任务", c) } -//获取定性考核任务列表 +// 获取定性考核任务列表 func (e *EvaluationInterface) QualitativeEvaluation(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -113,7 +113,7 @@ func (e *EvaluationInterface) QualitativeEvaluation(c *gin.Context) { response.Result(0, uotContAry, "用户端个人要执行的考核任务", c) } -//添加扣分或加分选项 +// 添加扣分或加分选项 func (e *EvaluationInterface) AdditionAndSubtractionScore(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -322,7 +322,7 @@ func (e *EvaluationInterface) AdditionAndSubtractionScore(c *gin.Context) { response.Result(0, outData, "数据写入成功", c) } -//添加责任人 +// 添加责任人 func (e *EvaluationInterface) AddDivisionResponsibility(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -589,7 +589,7 @@ func (e *EvaluationInterface) AddDivisionResponsibility(c *gin.Context) { response.Result(0, outData, "数据写入成功", c) } -//添加整改措施 +// 添加整改措施 func (e *EvaluationInterface) AddCorrectiveMeasures(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -725,7 +725,7 @@ func SendRectifyReceipt(sendUserList, mainTitle, mainTitleDesc, subtitle, reason return } -//获取定量考核任务列表 +// 获取定量考核任务列表 func (e *EvaluationInterface) QualitativeEvalRation(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -960,7 +960,7 @@ func (e *EvaluationInterface) QualitativeEvalRation(c *gin.Context) { response.Result(0, uotContAry, "用户端个人要执行的考核任务", c) } -//添加定量考核项目 +// 添加定量考核项目 func (e *EvaluationInterface) AddFlowRationLog(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -1250,7 +1250,7 @@ func (e *EvaluationInterface) AddFlowRationLog(c *gin.Context) { } } -//查看定性考核审批列表 +// 查看定性考核审批列表 func (e *EvaluationInterface) LookDutkScoreFlow(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -1557,7 +1557,7 @@ func (e *EvaluationInterface) LookDutkScoreFlow(c *gin.Context) { response.Result(0, dutyCecorFlowInfo, "获取成功", c) } -//查看定量考核列表 +// 查看定量考核列表 func (d *EvaluationInterface) LookRationkScoreFlow(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -1802,7 +1802,7 @@ func (d *EvaluationInterface) LookRationkScoreFlow(c *gin.Context) { response.Result(0, outListMap, "查询成功", c) } -//获取权重 +// 获取权重 func getPlanVersionWeghit(planKey, dimensionId, targetId string) (dimensionIdWeghit, targetIdWeghit int64) { var planVersionCont assessmentmodel.PlanVersio err := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.PlanVersio{}).Select("`content`").Where("`key` = ?", planKey).First(&planVersionCont).Error @@ -1827,7 +1827,7 @@ func getPlanVersionWeghit(planKey, dimensionId, targetId string) (dimensionIdWeg return } -//新查看定量考核列表 +// 新查看定量考核列表 func (e *EvaluationInterface) NewLookRationkScoreFlow(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/index/evaluation/examineflow.go b/api/index/evaluation/examineflow.go index ce42096..bfa4687 100644 --- a/api/index/evaluation/examineflow.go +++ b/api/index/evaluation/examineflow.go @@ -3,11 +3,11 @@ package evaluation import ( "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) @@ -171,7 +171,7 @@ func (e *EvaluationInterface) ExamineFlow(c *gin.Context) { response.Result(0, flowMap, "查询成功!", c) } -//获取人员信息 +// 获取人员信息 func GetApproveUser(key string) (returnUser commonus.UserListFlowAll) { // var userCont hrsystem.Personnel var userCont hrsystem.PersonArchives diff --git a/api/index/evaluation/flowsend.go b/api/index/evaluation/flowsend.go index 7dce070..f984a98 100644 --- a/api/index/evaluation/flowsend.go +++ b/api/index/evaluation/flowsend.go @@ -7,16 +7,16 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) -//加减分 +// 加减分 func (e *EvaluationInterface) PlusOrMinusPoints(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -324,7 +324,7 @@ func (e *EvaluationInterface) PlusOrMinusPoints(c *gin.Context) { } } -//添加责任人 +// 添加责任人 func (e *EvaluationInterface) PersonInCharge(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -634,7 +634,7 @@ func (e *EvaluationInterface) PersonInCharge(c *gin.Context) { } -//判断是否已经存在 +// 判断是否已经存在 func judgeIsSet(id int64, idAry []int64) (isTrue bool) { isTrue = false for _, v := range idAry { @@ -645,7 +645,7 @@ func judgeIsSet(id int64, idAry []int64) (isTrue bool) { return } -//填写整改措施 +// 填写整改措施 func (e *EvaluationInterface) RectificationMeasures(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -807,7 +807,7 @@ func (e *EvaluationInterface) RectificationMeasures(c *gin.Context) { } -//写入责任节点 +// 写入责任节点 func WritePersonLiable(flowKey, userKey []int64) { var userAry []hrsystem.PersonArchives userAryErr := global.GVA_DB_HrDataBase.Model(&hrsystem.PersonArchives{}).Where("`key` IN ?", userKey).Find(&userAry) diff --git a/api/index/evaluation/flowsendnew.go b/api/index/evaluation/flowsendnew.go index 9637265..6ae93fa 100644 --- a/api/index/evaluation/flowsendnew.go +++ b/api/index/evaluation/flowsendnew.go @@ -7,15 +7,15 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//加减分 +// 加减分 func (e *EvaluationInterface) PlusOrMinusPointsNewYuan(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -323,7 +323,7 @@ func (e *EvaluationInterface) PlusOrMinusPointsNewYuan(c *gin.Context) { response.Result(0, outMap, "数据写入成功", c) } -//加减分 +// 加减分 func (e *EvaluationInterface) PlusOrMinusPointsNew(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/index/evaluation/lookquantita.go b/api/index/evaluation/lookquantita.go index cbbf632..9be9db9 100644 --- a/api/index/evaluation/lookquantita.go +++ b/api/index/evaluation/lookquantita.go @@ -6,14 +6,14 @@ import ( "strconv" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//查看定量考核目标设定 +// 查看定量考核目标设定 func (e *EvaluationInterface) LookQuantitativeConfig(c *gin.Context) { var requestData SelectQuantitativeConfig err := c.ShouldBindJSON(&requestData) @@ -114,7 +114,7 @@ func (e *EvaluationInterface) LookQuantitativeConfig(c *gin.Context) { response.Result(0, outList, "获取成功!", c) } -//查看审批流程 +// 查看审批流程 func (e *EvaluationInterface) SeeFlowLogOld(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/index/evaluation/sendwechatmsg.go b/api/index/evaluation/sendwechatmsg.go index 50ef566..1fb6cd2 100644 --- a/api/index/evaluation/sendwechatmsg.go +++ b/api/index/evaluation/sendwechatmsg.go @@ -5,12 +5,12 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) -//编辑流程步进器 +// 编辑流程步进器 func EiteDutiesInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.EvaluationProcess{}).Where("`ep_id` = ?", saveId).Updates(saveData).Error @@ -21,7 +21,7 @@ func EiteDutiesInfoes(saveId int64, saveData map[string]interface{}) (isTrue boo return } -//编辑分数流水 +// 编辑分数流水 func EiteScoreFlow(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.ScoreFlow{}).Where("`sf_key` = ?", saveId).Updates(saveData).Error diff --git a/api/index/evaluation/type.go b/api/index/evaluation/type.go index 014368f..024450c 100644 --- a/api/index/evaluation/type.go +++ b/api/index/evaluation/type.go @@ -1,13 +1,13 @@ package evaluation import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/assessmentmodel" ) type EvaluationInterface struct{} -//考核方案细则列表输出 +// 考核方案细则列表输出 type TargetContOutCont struct { Id string `json:"id"` Type int `json:"type"` @@ -46,20 +46,20 @@ type TargetContOutCont struct { PlanVersionNumber string `json:"planversionnumber"` //版本号 } -//定性考核列表输出 +// 定性考核列表输出 type QualEvalArrt struct { Id string `json:"id"` Name string `json:"name"` } -//附件格式 +// 附件格式 type EnclosureFormat struct { FileName string `json:"filename"` //附件名称 FilePath string `json:"filepath"` //附件地址 Type int `json:"type"` //附件类型 } -//加减分数据获取项 +// 加减分数据获取项 type addPlusOrMinusPoints struct { PlanId string `json:"planid"` //方案id Addtime string `json:"time"` //检查时间 @@ -80,7 +80,7 @@ type enclosureType struct { FilePath string `json:"filepath"` //文件路径 } -//划分责任人 +// 划分责任人 type DivisionResponsibilityType struct { Id string `json:"id"` //提交审批流ID UserList []DivisionResponsibilityUser `json:"userlist"` //责任人 @@ -104,7 +104,7 @@ type DivisionResponsibilityUsers struct { Weight int64 `json:"weight"` //权重 } -//流程步进 +// 流程步进 type FlowStep struct { Step int `json:"step"` //当前是第几步 Key string `json:"key"` //任务卡ID @@ -116,7 +116,7 @@ type FlowStep struct { NextStep int `json:"nextstep"` //下一步 1:创建;2:创建人部门负责人审批:3:责任划分;4:责任部门审批;5:主要责任人整改;6:责任部门审批;7:验收 } -//改正措施数据提交 +// 改正措施数据提交 type CorrectiveMeasuresType struct { OrderId string `json:"orderid"` Content string `json:"content"` //整改内容 @@ -126,7 +126,7 @@ type CorrectiveMeasuresType struct { Enclosure []commonus.EnclosureFormat `json:"enclosure"` //附件 } -//添加定量考核 +// 添加定量考核 type AddRationFlowLog struct { GroupId string `json:"groupid"` DepartmentID string `json:"departmentid"` @@ -148,7 +148,7 @@ type RationLogList struct { // PlanVersionNumber string `json:"planversionnumber"` //版本号 } -//获取定量考核列表 +// 获取定量考核列表 type GetRationFlowLog struct { GroupId string `json:"groupid"` DepartmentID string `json:"departmentid"` @@ -156,7 +156,7 @@ type GetRationFlowLog struct { Title string `json:"title"` } -//定性指标流程展示 +// 定性指标流程展示 type DutyCecorFlow struct { Title string `json:"title"` //审批流标识 OrderId string `json:"orderid"` //审批流标识 @@ -177,7 +177,7 @@ type DutyCecorFlow struct { ApprovalRecord []FlowContLog `json:"approvalrecord"` //审批记录 } -//审批操作 +// 审批操作 type FlowContLog struct { Name string `json:"name"` Icon string `json:"icon"` //头像 @@ -187,7 +187,7 @@ type FlowContLog struct { TimeVal string `json:"timeval"` //操作时间 } -//审批流 +// 审批流 type TechnologicalProcessType struct { Step int `json:"step"` State int `json:"state"` //状态 @@ -207,14 +207,14 @@ type caoZuoRen struct { TeamName string `json:"teamname"` //班组 } -//责任划分 +// 责任划分 type DivisiosibilityType struct { Type string `json:"type"` UserName string `json:"username"` Weight int64 `json:"weight"` } -//整改项目 +// 整改项目 type RectifMeasures struct { RecName string `json:"recname"` //整改人 RecCont string `json:"reccont"` //整改内容 @@ -223,7 +223,7 @@ type RectifMeasures struct { Enclosure []EnclosureFormat `json:"enclosure"` //附件 } -//定量考核审批输出 +// 定量考核审批输出 type RationOutStruct struct { Id string `json:"id"` FlowId string `flowid` @@ -241,7 +241,7 @@ type RationOutStruct struct { Weight float64 `json:"weight"` } -//定量考核目标设定查询 +// 定量考核目标设定查询 type SelectQuantitativeConfig struct { GroupId string `json:"groupid"` DepartmentID string `json:"departmentid"` @@ -254,7 +254,7 @@ type SelectQuantitativeConfig struct { State int `json:"state"` //状态(1、启用;2、禁用;3、删除) } -//输出 +// 输出 type OutQuantitativeConfig struct { assessmentmodel.QuantitativeConfig GroupTitle string `json:"grouptitle"` //操作组 @@ -272,7 +272,7 @@ type MainResponsiblePersonType struct { Weight int64 `json:"weight"` } -//流程记录 +// 流程记录 type FlowLogType struct { commonus.PageSetLimt State int `json:"state"` //状态 @@ -283,7 +283,7 @@ type FlowLogType struct { Class int `json:"class"` //0:全部;1:定性;2:定量 } -//流程记录输出 +// 流程记录输出 type FlowLogListOut struct { OutId string `json:"outid"` //id Title string `json:"tittle"` //流程名 @@ -307,14 +307,14 @@ type FlowLogListOut struct { IsSet int `json:"isset"` //是否已经审批 } -//新定性考核列表 +// 新定性考核列表 type NewQualType struct { Group string `json:"group"` //集团 Department string `json:"department"` //部门 Title string `json:"tittle"` //指标名称 } -//新型定性考核列表输出 +// 新型定性考核列表输出 type NewQualOutList struct { Id int64 `json:"id" gorm:"primaryKey;column:qe_id;type:bigint(20) unsigned;not null;comment:Id;index"` Group int64 `json:"group" gorm:"column:qe_group;type:bigint(20) unsigned;default:0;not null;comment:归属集团"` @@ -329,7 +329,7 @@ type NewQualOutList struct { ScoreReduction float64 `json:"scorereduction"` //减分总计 } -//新定性考核指标细则列表 +// 新定性考核指标细则列表 type NewQualDetailTar struct { Group string `json:"group"` //集团 Department string `json:"department"` //部门 @@ -337,7 +337,7 @@ type NewQualDetailTar struct { Title string `json:"title"` } -//新型定性考核细则列表输出 +// 新型定性考核细则列表输出 type NewQualDetailOutList struct { NewQualOutList Id int64 `json:"id" gorm:"primaryKey;column:qe_id;type:bigint(20) unsigned;not null;comment:Id;index"` @@ -354,7 +354,7 @@ type NewQualDetailOutList struct { PlanVersionNumber string `json:"planversionnumber" gorm:"column:qe_qual_eval_id;type:varchar(200) unsigned;default:0;not null;comment:性质考核方案"` //版本号 } -//定量或者定性考核审批流程全图 +// 定量或者定性考核审批流程全图 type getExamineFlow struct { Id string `json:"id"` //考核项目ID IsCorrection int `json:"iscorrection"` //是否整改 @@ -369,7 +369,7 @@ type AddDutyNewCont struct { Child []EvaluPross `json:"child"` //考核细则 } -//指标 +// 指标 type EvaluPross struct { Id string `json:"id"` //维度ID Name string `json:"name"` @@ -384,7 +384,7 @@ type EvaluPross struct { Status int `json:"status"` } -//审批记录输出 +// 审批记录输出 type accPerFlowLog struct { assessmentmodel.EvaluationProcess DutyDepartment int64 `json:"dutydepartment" gorm:"column:sf_duty_department;type:bigint(20) unsigned;default:0;not null;comment:职责部门"` @@ -399,7 +399,7 @@ type accPerFlowLog struct { AcceptEvaluation int64 `json:"acceptevaluation" gorm:"column:qe_accept_evaluation;type:bigint(20) unsigned;default:0;not null;comment:接受考核部门"` } -//新定性考核列表 +// 新定性考核列表 type QualEvalFlowLog struct { Group string `json:"group"` //集团 Department string `json:"department"` //部门 @@ -411,7 +411,7 @@ type TongjiFenShu struct { Count float64 `json:"count" gorm:"column:sf_count;type:int(5) unsigned;default:1;not null;comment:发生次数"` } -//定量流水全奖值、零奖值、封顶值 +// 定量流水全奖值、零奖值、封顶值 type FlowLogAllZreo struct { Id string `json:"id"` Zeroprize float64 `json:"zeroprize"` //零奖值"` diff --git a/api/index/examineandapprove/examapp.go b/api/index/examineandapprove/examapp.go index cbdd7e2..5ecd146 100644 --- a/api/index/examineandapprove/examapp.go +++ b/api/index/examineandapprove/examapp.go @@ -5,20 +5,20 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//考核入口 +// 考核入口 func (e *ExamineApproveApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "用户端审批获取成功", c) } -//获取基础配置 +// 获取基础配置 func (e *ExamineApproveApi) GetConfing(c *gin.Context) { var requestData ExamConfig err := c.ShouldBindJSON(&requestData) diff --git a/api/index/statistics/dataform.go b/api/index/statistics/dataform.go index 822bb1e..5cfe122 100644 --- a/api/index/statistics/dataform.go +++ b/api/index/statistics/dataform.go @@ -6,15 +6,15 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/quantification" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/statistics/quantification" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//获取有效版本考核 +// 获取有效版本考核 func (a *ApiGroup) GetPlanVersionValides(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -597,7 +597,7 @@ func (a *ApiGroup) GetPlanVersionValides(c *gin.Context) { response.Result(0, outData, "获取成功", c) } -//获取总值 定量 +// 获取总值 定量 func AuxiliaryCalculationSumMethod(where interface{}, scoringMethod int) (sumScore float64, departmentAry []int64, departNameAry []string) { if scoringMethod == 2 { gormDb := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.FlowLogData{}).Joins("left join flow_log as fl on fl.fl_key = flow_log_data.fld_flow_log").Where(where) @@ -621,7 +621,7 @@ func AuxiliaryCalculationSumMethod(where interface{}, scoringMethod int) (sumSco return } -//定性 +// 定性 func SubjectiveAuxiliaryCalculationSumMethod(where interface{}) (sumScore float64, departmentAry []int64, departNameAry []string) { //加分 var addSumScore float64 = 0 diff --git a/api/index/statistics/enter.go b/api/index/statistics/enter.go index b9f1a00..5d48cea 100644 --- a/api/index/statistics/enter.go +++ b/api/index/statistics/enter.go @@ -3,7 +3,7 @@ package statistics import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/model/assessmentmodel" ) // 统计 diff --git a/api/index/statistics/newstatistics.go b/api/index/statistics/newstatistics.go index 56e1b13..b465e11 100644 --- a/api/index/statistics/newstatistics.go +++ b/api/index/statistics/newstatistics.go @@ -6,11 +6,11 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" "gorm.io/gorm" ) diff --git a/api/index/statistics/programme.go b/api/index/statistics/programme.go index 5f0adc4..22f03fd 100644 --- a/api/index/statistics/programme.go +++ b/api/index/statistics/programme.go @@ -7,21 +7,21 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/quantification" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/statistics/quantification" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//考核入口 +// 考核入口 func (a *ApiGroup) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "方案数据表格获取成功", c) } -//方案数据表格统计 +// 方案数据表格统计 func (a *ApiGroup) PlanVersioStatistics(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -57,7 +57,7 @@ func (a *ApiGroup) PlanVersioStatistics(c *gin.Context) { response.Result(0, outCont, "获取成功", c) } -//根据部门获取绩效考核数据统计表格 +// 根据部门获取绩效考核数据统计表格 func (a *ApiGroup) DepartPerAppDataStatistics(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -156,7 +156,7 @@ func (a *ApiGroup) DepartPerAppDataStatistics(c *gin.Context) { response.Result(0, statisticsAry, "查询完成", c) } -//判断集团是否存在 +// 判断集团是否存在 func judgeOrgStatic(id string, orgAry []OrgStatics) bool { for _, v := range orgAry { if id == v.Id { @@ -166,7 +166,7 @@ func judgeOrgStatic(id string, orgAry []OrgStatics) bool { return false } -//判断部门是否存在 +// 判断部门是否存在 func judegOrgDeparStatic(id, departId string, orgAry []OrgStatics) bool { for _, v := range orgAry { if id == v.Id { @@ -180,7 +180,7 @@ func judegOrgDeparStatic(id, departId string, orgAry []OrgStatics) bool { return false } -//统计值 +// 统计值 func StaticDataOperation(key, group, depart, staticFrame, year string) (staticDataAry []ProgrammeStatisticsCallBack, isTrue bool) { isTrue = false var planInfo []AddDutyNewCont diff --git a/api/index/statistics/queryresults.go b/api/index/statistics/queryresults.go index 5c1292c..be452bd 100644 --- a/api/index/statistics/queryresults.go +++ b/api/index/statistics/queryresults.go @@ -6,12 +6,12 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/quantification" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/api/statistics/quantification" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) diff --git a/api/index/statistics/tablestatistics.go b/api/index/statistics/tablestatistics.go index 030c214..1de276b 100644 --- a/api/index/statistics/tablestatistics.go +++ b/api/index/statistics/tablestatistics.go @@ -7,11 +7,11 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/quantification" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/statistics/quantification" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/json_callback/httpserver.go b/api/json_callback/httpserver.go index 9325f4a..5ab476e 100644 --- a/api/json_callback/httpserver.go +++ b/api/json_callback/httpserver.go @@ -9,7 +9,7 @@ import ( "net/url" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/wechatjiexi/wxbizjsonmsgcrypt" + "gin_server_admin/wechatjiexi/wxbizjsonmsgcrypt" ) const token = "gY1AGR3mjBhzy" diff --git a/api/json_callback/sample.go b/api/json_callback/sample.go index 7258c41..602d358 100644 --- a/api/json_callback/sample.go +++ b/api/json_callback/sample.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/wechatjiexi/wxbizjsonmsgcrypt" + "gin_server_admin/wechatjiexi/wxbizjsonmsgcrypt" ) // type MsgContent struct { diff --git a/api/publichandle/enter.go b/api/publichandle/enter.go index 6f97f62..7ccc879 100644 --- a/api/publichandle/enter.go +++ b/api/publichandle/enter.go @@ -1,6 +1,6 @@ package publichandle -import "github.com/flipped-aurora/gin-vue-admin/server/api/publichandle/userhandle" +import "gin_server_admin/api/publichandle/userhandle" type ApiGroup struct { GeographyApi userhandle.ApiGroup diff --git a/api/publichandle/userhandle/handel.go b/api/publichandle/userhandle/handel.go index 1e69076..6c8e975 100644 --- a/api/publichandle/userhandle/handel.go +++ b/api/publichandle/userhandle/handel.go @@ -5,21 +5,21 @@ import ( "strconv" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/callback" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/api/wechatapp/callback" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (g *GeographyUnknown) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "公共API入口获取成功", c) } -//获取地理位置上报人员信息 +// 获取地理位置上报人员信息 func (g *GeographyUnknown) LocationUserList(c *gin.Context) { var requestData GetLocLocationUserPage err := c.ShouldBindJSON(&requestData) @@ -48,7 +48,7 @@ func (g *GeographyUnknown) LocationUserList(c *gin.Context) { response.Result(101, output, "参数错误!请重新提交!", c) } -//获取所有地理位置上报人员信息 +// 获取所有地理位置上报人员信息 func (g *GeographyUnknown) LocationUserListAll(c *gin.Context) { redisPrefix := "Location:GeographicalPosition_" + global.GVA_CONFIG.RedisPrefix.PreFix + ":userId_*" //redis KEY redisClient := redishandel.RunRedis() @@ -80,7 +80,7 @@ func (g *GeographyUnknown) LocationUserListAll(c *gin.Context) { response.Result(0, output, "数据获取成功!", c) } -//获取人员上报地址点位 +// 获取人员上报地址点位 func (g *GeographyUnknown) GetLocationUserAddress(c *gin.Context) { var requestData GetWechatWorkId err := c.ShouldBindJSON(&requestData) diff --git a/api/publichandle/userhandle/type.go b/api/publichandle/userhandle/type.go index 7f323f8..97779b3 100644 --- a/api/publichandle/userhandle/type.go +++ b/api/publichandle/userhandle/type.go @@ -1,6 +1,6 @@ package userhandle -import "github.com/flipped-aurora/gin-vue-admin/server/commonus" +import "gin_server_admin/commonus" //地理未知 type GeographyUnknown struct{} diff --git a/api/reply/enter.go b/api/reply/enter.go index 7e9c81f..0cb877e 100644 --- a/api/reply/enter.go +++ b/api/reply/enter.go @@ -1,13 +1,13 @@ package reply import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/reply/qual" - "github.com/flipped-aurora/gin-vue-admin/server/api/reply/quan" + "gin_server_admin/api/reply/qual" + "gin_server_admin/api/reply/quan" ) //自建审批 -//企业微信应用 +// 企业微信应用 type ApiGroup struct { QuanAipGroup quan.ApiGroup QualApiGroup qual.ApiGroup diff --git a/api/reply/qual/controller.go b/api/reply/qual/controller.go index dc72d08..40d43aa 100644 --- a/api/reply/qual/controller.go +++ b/api/reply/qual/controller.go @@ -6,15 +6,15 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//定性审批解析 +// 定性审批解析 func (a *ApiGroup) Operation(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/reply/qual/divisionrectification.go b/api/reply/qual/divisionrectification.go index c1e4f03..ad32f9b 100644 --- a/api/reply/qual/divisionrectification.go +++ b/api/reply/qual/divisionrectification.go @@ -7,16 +7,16 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) -//责任划分 +// 责任划分 func (a *ApiGroup) DivisionResponsibility(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -368,7 +368,7 @@ func (a *ApiGroup) DivisionResponsibility(c *gin.Context) { response.Result(0, outMap, "数据写入成功", c) } -//填写整改措施 +// 填写整改措施 func (a *ApiGroup) AmendMeasures(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -550,7 +550,7 @@ func (a *ApiGroup) AmendMeasures(c *gin.Context) { response.Result(0, outMap, "数据写入成功", c) } -//写入责任节点 +// 写入责任节点 func WritePersonLiable(flowKey int64, userKey []int64) { var userAry []hrsystem.PersonArchives userAryErr := global.GVA_DB_HrDataBase.Model(&hrsystem.PersonArchives{}).Where("`key` IN ?", userKey).Find(&userAry).Error diff --git a/api/reply/qual/enter.go b/api/reply/qual/enter.go index b1d652f..76d0d8f 100644 --- a/api/reply/qual/enter.go +++ b/api/reply/qual/enter.go @@ -1,22 +1,22 @@ package qual import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//企业微信回调 +// 企业微信回调 type ApiGroup struct { } -//入口 +// 入口 func (a *ApiGroup) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "定性审批端获取成功", c) } -//审批参数 +// 审批参数 type ApprovalParameters struct { OrderId string `json:"orderid"` //流程单KEY YesOrNo int `json:"yesorno"` //1:同意;2:驳回 diff --git a/api/reply/quan/controller.go b/api/reply/quan/controller.go index afbc1d1..1c2b6a9 100644 --- a/api/reply/quan/controller.go +++ b/api/reply/quan/controller.go @@ -6,15 +6,15 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//定量审批 +// 定量审批 func (a *ApiGroup) Sanction(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/reply/quan/enter.go b/api/reply/quan/enter.go index 962c4b9..12253c2 100644 --- a/api/reply/quan/enter.go +++ b/api/reply/quan/enter.go @@ -1,22 +1,22 @@ package quan import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//企业微信回调 +// 企业微信回调 type ApiGroup struct { } -//入口 +// 入口 func (a *ApiGroup) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "定量审批端获取成功", c) } -//添加定量考核 +// 添加定量考核 type AddRationFlowLog struct { GroupId string `json:"groupid"` DepartmentID string `json:"departmentid"` @@ -41,7 +41,7 @@ type RationLogList struct { Cycle int `json:"cycle"` //1:班;2:天;3:周;4:月;5:季度;6:年;7:半年 } -//审批参数 +// 审批参数 type ApprovalParameters struct { OrderId string `json:"orderid"` //流程单KEY YesOrNo int `json:"yesorno"` //1:同意;2:驳回 @@ -61,7 +61,7 @@ type TimeAllDay struct { ToDay int64 `json:"today"` //天"` } -//定量流水全奖值、零奖值、封顶值 +// 定量流水全奖值、零奖值、封顶值 type FlowLogAllZreo struct { Id string `json:"id"` TargetId string `json:"targetid"` //指标ID` diff --git a/api/reply/quan/ration.go b/api/reply/quan/ration.go index af40c47..c27d684 100644 --- a/api/reply/quan/ration.go +++ b/api/reply/quan/ration.go @@ -7,11 +7,11 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/statistics/enter.go b/api/statistics/enter.go index 1e00524..b3962e0 100644 --- a/api/statistics/enter.go +++ b/api/statistics/enter.go @@ -1,8 +1,8 @@ package statistics import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/nature" - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics/quantification" + "gin_server_admin/api/statistics/nature" + "gin_server_admin/api/statistics/quantification" ) type ApiGroup struct { diff --git a/api/statistics/nature/statistics.go b/api/statistics/nature/statistics.go index 7507561..aebf287 100644 --- a/api/statistics/nature/statistics.go +++ b/api/statistics/nature/statistics.go @@ -5,20 +5,20 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (a *ApiGroup) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "手机考核入口", c) } -//计算定性考核组织范围,及起止年份 +// 计算定性考核组织范围,及起止年份 func (a *ApiGroup) GetTargetOrgAndYear(c *gin.Context) { isTrue, _ := commonus.ClientIdentity() if isTrue != true { @@ -144,7 +144,7 @@ func (a *ApiGroup) GetTargetOrgAndYear(c *gin.Context) { response.Result(0, outMap, "数据获取失败!", c) } -//获取存在的组织架构 +// 获取存在的组织架构 func getExistOrg(targetId string) []orgModelsAry { var releDepart string var orgMap []orgModelsAry @@ -200,7 +200,7 @@ func getExistOrg(targetId string) []orgModelsAry { return orgMap } -//定性考核统计 +// 定性考核统计 func (a *ApiGroup) NatureStatistics(c *gin.Context) { isTrue, _ := commonus.ClientIdentity() if isTrue != true { @@ -222,7 +222,7 @@ func (a *ApiGroup) NatureStatistics(c *gin.Context) { } } -//计算指标相关数值 +// 计算指标相关数值 func calculationEvaluation(taskId string, dataAry natureParameter) (err error) { var scorFlowList []assessmentmodel.ScoreFlow gormDb := global.GVA_DB_Performanceappraisal.Where("`sf_evaluation_plan` = ?", taskId) diff --git a/api/statistics/quantification/auxiliarycalculation.go b/api/statistics/quantification/auxiliarycalculation.go index 7e32b67..2ffa82a 100644 --- a/api/statistics/quantification/auxiliarycalculation.go +++ b/api/statistics/quantification/auxiliarycalculation.go @@ -5,26 +5,26 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) -//获取总值 +// 获取总值 func AuxiliaryCalculationSum(where interface{}) (sumScore float64) { gormDb := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.FlowLogData{}).Joins("left join flow_log as fl on fl.fl_key = flow_log_data.fld_flow_log").Where(where) gormDb.Pluck("COALESCE(SUM(fld_score), 0) as rescore", &sumScore) return } -//获取总数 +// 获取总数 func AuxiliaryCalculationCount(where interface{}) (sumScore float64) { gormDb := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.FlowLogData{}).Joins("left join flow_log as fl on fl.fl_key = flow_log_data.fld_flow_log").Where(where) gormDb.Pluck("COALESCE(COUNT(fld_id), 0) as countid", &sumScore) //获取总数 return } -//计算总值和平均值 +// 计算总值和平均值 func AverageOfSum(where interface{}, class ...int) (sumScore float64, averageScore float64) { sumScore = AuxiliaryCalculationSum(where) / 100 if len(class) > 0 { diff --git a/api/statistics/quantification/departmentstatisc.go b/api/statistics/quantification/departmentstatisc.go index a29a507..f1e2f9f 100644 --- a/api/statistics/quantification/departmentstatisc.go +++ b/api/statistics/quantification/departmentstatisc.go @@ -5,9 +5,9 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) //行政维度统计计算 diff --git a/api/statistics/quantification/enter.go b/api/statistics/quantification/enter.go index 750c715..2badcef 100644 --- a/api/statistics/quantification/enter.go +++ b/api/statistics/quantification/enter.go @@ -3,9 +3,9 @@ package quantification import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) diff --git a/api/statistics/quantification/jisuanshuzhi.go b/api/statistics/quantification/jisuanshuzhi.go index dfe5da6..6d7d53f 100644 --- a/api/statistics/quantification/jisuanshuzhi.go +++ b/api/statistics/quantification/jisuanshuzhi.go @@ -4,9 +4,9 @@ import ( "encoding/json" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) //计算数值用的 @@ -39,14 +39,14 @@ func AuxiliaryCalculationSumNature(where interface{}) (sumScore float64) { // return sumScore * -1 } -//获取定性总数 +// 获取定性总数 func AuxiliaryCalculationCountNature(where interface{}) (sumScore float64) { gormDb := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.ScoreFlow{}).Where(where).Where("sf_reply IN (2,3)") gormDb.Pluck("COALESCE(COUNT(sf_id), 0) as countid", &sumScore) //获取总数 return } -//计算总值和平均值 +// 计算总值和平均值 func AverageOfSumNature(where interface{}, class ...int) (sumScore float64, averageScore float64) { sumScore = AuxiliaryCalculationSumNature(where) / 100 // panic(sumScore) @@ -65,7 +65,7 @@ func AverageOfSumNature(where interface{}, class ...int) (sumScore float64, aver return } -//统计查询条件 +// 统计查询条件 func (d *dataLockStatistics) StatisticalQueryCriteria(qualId int64) { d.mutext.Lock() defer d.mutext.Unlock() diff --git a/api/statistics/quantification/quant.go b/api/statistics/quantification/quant.go index afe191d..cd2c6c4 100644 --- a/api/statistics/quantification/quant.go +++ b/api/statistics/quantification/quant.go @@ -4,15 +4,15 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) -//量化考核图标 +// 量化考核图标 func (a *ApiGroup) GetQuantEChartOrgAndYear(c *gin.Context) { isTrue, _ := commonus.ClientIdentity() if isTrue != true { @@ -105,7 +105,7 @@ func bianLiOrg(guoDuOrm, outOrm []orgModels) (ormAry []orgModels) { return } -//量化考核图标 +// 量化考核图标 func (a *ApiGroup) QuantEChart(c *gin.Context) { isTrue, _ := commonus.ClientIdentity() if isTrue != true { @@ -248,7 +248,7 @@ func getGroupOrgList(orgAry []string) (orgMap []orgModelsAry, orgWherList []orgM return } -//获取行政组织 +// 获取行政组织 func getGroupOrg(orgAry []string) (orgMap []orgModelsAry, orgWherList []orgModels) { var govMap []OutGovCont diff --git a/api/statistics/quantification/shiyan.go b/api/statistics/quantification/shiyan.go index 08acba8..b35f855 100644 --- a/api/statistics/quantification/shiyan.go +++ b/api/statistics/quantification/shiyan.go @@ -3,7 +3,7 @@ package quantification import ( "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" + "gin_server_admin/commonus" ) //维度计算 diff --git a/api/statistics/quantification/summary_details.go b/api/statistics/quantification/summary_details.go index f0cbe47..f472109 100644 --- a/api/statistics/quantification/summary_details.go +++ b/api/statistics/quantification/summary_details.go @@ -6,12 +6,12 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/admin/dutyassess" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/api/admin/dutyassess" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) diff --git a/api/statistics/quantification/timestatistics.go b/api/statistics/quantification/timestatistics.go index 94bb9da..463650e 100644 --- a/api/statistics/quantification/timestatistics.go +++ b/api/statistics/quantification/timestatistics.go @@ -4,9 +4,9 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) //以时间维度查询统计 @@ -1010,7 +1010,7 @@ func TimeDimensionStatistics(taskId string, dataAry natureParameter) (outputData return } -//获取指标关联的部门 +// 获取指标关联的部门 func GetTargerDepartment(dimension, targerId int64) (departID []string) { var taskIdAry []int64 global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Select("qe_accept_evaluation").Where("qe_state = 1 AND qe_dimension = ? AND qe_target = ?", dimension, targerId).Find(&taskIdAry) diff --git a/api/textcomparison/chinatopinyin.go b/api/textcomparison/chinatopinyin.go new file mode 100644 index 0000000..a754773 --- /dev/null +++ b/api/textcomparison/chinatopinyin.go @@ -0,0 +1,57 @@ +package textcomparison + +import ( + "fmt" + "strings" + + "github.com/Chain-Zhang/pinyin" +) + +/* +* +@ 作者: 秦东 +@ 时间: 2022-09-30 16:00:42 +@ 功能: 中文转拼音 +@ 参数 + + #text 中文 + +@ 返回值 + + #pinYinStr 拼音 + #err 错误信息 +*/ +func ChinaToPinYinFirstBig(text string) (pinYinStr string, err error) { + pinYinStr, err = pinyin.New(text).Split("").Mode(pinyin.InitialsInCapitals).Convert() + return +} + +/* +* +@ 作者: 秦东 +@ 时间: 2022-09-30 16:08:40 +@ 功能: 获取首字母 +@ 参数 + + # + +@ 返回值 + + # +*/ +func ChinaToPinYinFirstWord(text string) (pinYinStr string, err error) { + pinYinStrAll, err := pinyin.New(text).Convert() + pinYinAry := strings.Split(pinYinStrAll, " ") + if len(pinYinAry) < 1 { + err = fmt.Errorf("转译错误!") + return + } + for i := 0; i < len(pinYinAry); i++ { + if len(pinYinAry[i]) > 0 { + ziMuStr := pinYinAry[i][0] + firstWord := strings.ToUpper(string(ziMuStr)) + pinYinStr = fmt.Sprintf("%v%v", pinYinStr, firstWord) + } + } + return +} diff --git a/api/textcomparison/goJieba.go b/api/textcomparison/goJieba.go deleted file mode 100644 index 8115a1a..0000000 --- a/api/textcomparison/goJieba.go +++ /dev/null @@ -1,83 +0,0 @@ -package textcomparison - -import ( - "sync" - - "github.com/yanyiwu/gojieba" -) - -type GoJieba struct { - C *gojieba.Jieba -} - -var GJB *GoJieba -var one sync.Once - -func NewGoJieba() *GoJieba { - one.Do(func() { - GJB = &GoJieba{ - C: gojieba.NewJieba(), - //equals with x := NewJieba(DICT_PATH, HMM_PATH, USER_DICT_PATH) - } - }) - return GJB -} - -func (this *GoJieba) Close() { - this.C.Free() -} - -func (this *GoJieba) AddWords(words []string) { - for _, word := range words { - this.C.AddWord(word) - } -} - -func (this *GoJieba) JiebaCut(rawStr string, useHmm bool, cutAll bool) (words []string) { - if cutAll { - words = jiebaCutAll(this.C, &rawStr) - } else { - words = jiebaCut(this.C, &rawStr, useHmm) - } - - return -} - -func (this *GoJieba) JiebaCutWithFrequency(rawStr string, useHmm bool, cutAll bool) (wordsFreqs map[string]int) { - wordsFreqs = make(map[string]int) - if cutAll { - words := jiebaCutAll(this.C, &rawStr) - for _, word := range words { - freq := wordsFreqs[word] - wordsFreqs[word] = freq + 1 - } - } else { - words := jiebaCut(this.C, &rawStr, useHmm) - for _, word := range words { - freq := wordsFreqs[word] - wordsFreqs[word] = freq + 1 - } - } - - return -} - -func (this *GoJieba) JiebaCutForSearch(rawStr string, useHmm bool) { - jiebaCut4Search(this.C, &rawStr, useHmm) - -} - -func jiebaCutAll(x *gojieba.Jieba, rawStr *string) (words []string) { - words = x.CutAll(*rawStr) - return -} - -func jiebaCut(x *gojieba.Jieba, rawStr *string, useHmm bool) (words []string) { - words = x.Cut(*rawStr, useHmm) - return -} - -func jiebaCut4Search(x *gojieba.Jieba, rawStr *string, useHmm bool) (words []string) { - words = x.CutForSearch(*rawStr, useHmm) - return -} diff --git a/api/v1/archiveapi/archiveapihandle.go b/api/v1/archiveapi/archiveapihandle.go index 4b7dd97..5565255 100644 --- a/api/v1/archiveapi/archiveapihandle.go +++ b/api/v1/archiveapi/archiveapihandle.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/archivesmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/archivesmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -18,7 +18,7 @@ func (a *ArchiveApiHandle) Index(c *gin.Context) { response.Result(0, outPut, "获取成功", c) } -//栏目列表 +// 栏目列表 func (a *ArchiveApiHandle) ArchiveTypeList(c *gin.Context) { var requestData archiveTypeListStruct err := c.ShouldBindJSON(&requestData) @@ -74,7 +74,7 @@ func (a *ArchiveApiHandle) ArchiveTypeList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加栏目 +// 添加栏目 func (a *ArchiveApiHandle) AddArchive(c *gin.Context) { var arrData appArchiveType err := c.ShouldBindJSON(&arrData) @@ -110,7 +110,7 @@ func (a *ArchiveApiHandle) AddArchive(c *gin.Context) { } } -//获取单个信息栏目 +// 获取单个信息栏目 func (a *ArchiveApiHandle) GetArchiveInfo(c *gin.Context) { var arrData commonus.SetId err := c.ShouldBindJSON(&arrData) @@ -155,7 +155,7 @@ func (a *ArchiveApiHandle) GetArchiveInfo(c *gin.Context) { response.Result(0, outPutInfo, "获取成功!", c) } -//改变栏目状态 +// 改变栏目状态 func (a *ArchiveApiHandle) EiteArchiveState(c *gin.Context) { var arrData archiveState err := c.ShouldBindJSON(&arrData) @@ -206,7 +206,7 @@ func (a *ArchiveApiHandle) EiteArchiveState(c *gin.Context) { } } -//状态软操作 +// 状态软操作 func archiveStateSet(archiveInfo archivesmodel.ArchivesType, arrData archiveState) (isTrue bool, archiveInfoErr error) { isTrue = false //软处理 @@ -221,7 +221,7 @@ func archiveStateSet(archiveInfo archivesmodel.ArchivesType, arrData archiveStat return } -//修改栏目信息 +// 修改栏目信息 func (a *ArchiveApiHandle) EiteArchiveInfo(c *gin.Context) { var arrData eiteArchiveCont err := c.ShouldBindJSON(&arrData) @@ -261,7 +261,7 @@ func (a *ArchiveApiHandle) EiteArchiveInfo(c *gin.Context) { response.Result(0, err, "修改成功!", c) } -//批量修改栏目 +// 批量修改栏目 func (a *ArchiveApiHandle) BatchEiteArchiveState(c *gin.Context) { var arrData batchArchiveState err := c.ShouldBindJSON(&arrData) @@ -305,7 +305,7 @@ func (a *ArchiveApiHandle) BatchEiteArchiveState(c *gin.Context) { } } -//批量状态软操作 +// 批量状态软操作 func batchArchiveStateSet(archiveInfo archivesmodel.ArchivesType, arrData batchArchiveState) (isTrue bool, archiveInfoErr error) { isTrue = false //软处理 diff --git a/api/v1/archiveapi/graphicinformation.go b/api/v1/archiveapi/graphicinformation.go index 86ed8e6..f715322 100644 --- a/api/v1/archiveapi/graphicinformation.go +++ b/api/v1/archiveapi/graphicinformation.go @@ -5,18 +5,18 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/archivesmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/archivesmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) -//图文信息模块 +// 图文信息模块 type GraphicInformation struct{} -//文档列表 +// 文档列表 func (g *GraphicInformation) ArchiveFileList(c *gin.Context) { var requestData fileList err := c.ShouldBindJSON(&requestData) @@ -143,7 +143,7 @@ func (g *GraphicInformation) ArchiveFileList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取文档属性 global.GVA_DB_BookDate +// 获取文档属性 global.GVA_DB_BookDate func getBookArrter(id int64) (Reading, Comment, Collect, Likes, Tread, Score int64) { var bookAttr archivesmodel.BookAttribute readingErr := global.GVA_DB_BookDate.Model(&bookAttr).Where("`b_file_id` = ? AND `b_stater` = ? AND `b_type` = ?", id, 1, 1).Count(&Reading).Error @@ -170,7 +170,7 @@ func getBookArrter(id int64) (Reading, Comment, Collect, Likes, Tread, Score int return } -//添加文档 +// 添加文档 func (g *GraphicInformation) AddArchiveFileInfo(c *gin.Context) { var archiveFileInfo archivesmodel.ArchiveFile archiveFileInfo.InitInfo() @@ -222,7 +222,7 @@ func (g *GraphicInformation) AddArchiveFileInfo(c *gin.Context) { } } -//获取文档信息 +// 获取文档信息 func (g *GraphicInformation) GetArchiveFileInfo(c *gin.Context) { var getID commonus.SetId err := c.ShouldBindJSON(&getID) @@ -253,7 +253,7 @@ func (g *GraphicInformation) GetArchiveFileInfo(c *gin.Context) { } } -//修改文档信息 +// 修改文档信息 func (g *GraphicInformation) EiteArchiveFileInfo(c *gin.Context) { var archiveFileInfo archivesmodel.ArchiveFile err := c.ShouldBindJSON(&archiveFileInfo) @@ -316,7 +316,7 @@ func (g *GraphicInformation) EiteArchiveFileInfo(c *gin.Context) { response.Result(0, archiveFileInfo, "数据写入成功!", c) } -//状态修改及软硬删除文档信息 +// 状态修改及软硬删除文档信息 func (g *GraphicInformation) ModifyArchiveFileInfo(c *gin.Context) { var arrData archiveState err := c.ShouldBindJSON(&arrData) @@ -366,7 +366,7 @@ func (g *GraphicInformation) ModifyArchiveFileInfo(c *gin.Context) { } } -//修改文档状态 +// 修改文档状态 func eiteArchiveFileState(arrData archiveState) (isTrue bool) { isTrue = false //软处理 @@ -382,7 +382,7 @@ func eiteArchiveFileState(arrData archiveState) (isTrue bool) { return } -//批量删除 +// 批量删除 func (g *GraphicInformation) BatchDeleteArchiveFile(c *gin.Context) { var arrData batchArchiveState err := c.ShouldBindJSON(&arrData) @@ -424,7 +424,7 @@ func (g *GraphicInformation) BatchDeleteArchiveFile(c *gin.Context) { } } -//批量修改文档状态 +// 批量修改文档状态 func batchEiteArchiveFileState(arrData batchArchiveState) (isTrue bool) { isTrue = false //软处理 @@ -440,7 +440,7 @@ func batchEiteArchiveFileState(arrData batchArchiveState) (isTrue bool) { return } -//获取文档属性列表 +// 获取文档属性列表 func (g *GraphicInformation) GetArchiveFileAttributeList(c *gin.Context) { var fileAttribute archiveFileAttr err := c.ShouldBindJSON(&fileAttribute) @@ -506,7 +506,7 @@ func (g *GraphicInformation) GetArchiveFileAttributeList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//获取人员信息 +// 获取人员信息 func GetUserInfo(field []string, whereMap map[string]interface{}) (userCont testpage.PersonalDetails, isTrue bool) { isTrue = false var userInfo testpage.WorkMan @@ -517,7 +517,7 @@ func GetUserInfo(field []string, whereMap map[string]interface{}) (userCont test return } -//获取归档评论列表 +// 获取归档评论列表 func (g *GraphicInformation) GetDiscussFileMsg(c *gin.Context) { var fileAttribute archiveFileAttr err := c.ShouldBindJSON(&fileAttribute) diff --git a/api/v1/archiveapi/requestdata.go b/api/v1/archiveapi/requestdata.go index b982cfe..9f594aa 100644 --- a/api/v1/archiveapi/requestdata.go +++ b/api/v1/archiveapi/requestdata.go @@ -1,19 +1,19 @@ package archiveapi import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/archivesmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/archivesmodel" ) //ID -//文档接收列表 +// 文档接收列表 type archiveTypeListStruct struct { commonus.PageSetLimt ParentId int64 `json:"parentId"` } -//文档类型输出格式 +// 文档类型输出格式 type archiveTypeOutPut struct { commonus.SetId ColumnrName string `json:"columnr_name"` //栏目名称 @@ -21,7 +21,7 @@ type archiveTypeOutPut struct { State bool `json:"state"` // 状态 } -//添加栏目 +// 添加栏目 type appArchiveType struct { UID int64 `json:"uid"` //添加人 ParentId int64 `json:"parentId"` //父级 @@ -29,27 +29,27 @@ type appArchiveType struct { Sort int `json:"sort"` // 排序 } -//状态修改 +// 状态修改 type archiveState struct { commonus.SetId State int `json:"state"` // 状态 IsDel int `json:"isdel"` // 是否强制删除 } -//批量 +// 批量 type batchArchiveState struct { commonus.BatchId State int `json:"state"` // 状态 IsDel int `json:"isdel"` // 是否强制删除 } -//修改栏目 +// 修改栏目 type eiteArchiveCont struct { commonus.SetId appArchiveType } -//文档列表查询 +// 文档列表查询 type fileList struct { commonus.PageSetLimt ParentId int64 `json:"parentId"` //父级 @@ -59,7 +59,7 @@ type fileList struct { GroupStruct } -//组织架构相关 +// 组织架构相关 type GroupStruct struct { Group int64 `json:"group"` //集团 Factory int64 `json:"factory"` //分厂 @@ -67,7 +67,7 @@ type GroupStruct struct { Team int64 `json:"team"` //班组 } -//文档列表返回结构 +// 文档列表返回结构 type callBackFilesList struct { commonus.SetId Title string `json:"title"` //标题 @@ -85,14 +85,14 @@ type callBackFilesList struct { State bool `json:"state"` //状态 } -//文档属性列表 +// 文档属性列表 type archiveFileAttr struct { commonus.PageSetLimt FileID int64 `json:"fileID"` Type int `json:"type"` } -//文档属性列表输出 +// 文档属性列表输出 type archiveFileAttrOutPut struct { archivesmodel.BookAttribute Number string `json:"number"` @@ -100,7 +100,7 @@ type archiveFileAttrOutPut struct { OutId string `json:"outID"` } -//文档评论属性列表输出 +// 文档评论属性列表输出 type archiveFileDiscussAttrOutPut struct { archivesmodel.DiscussMsg Number string `json:"number"` @@ -108,7 +108,7 @@ type archiveFileDiscussAttrOutPut struct { UserJsonCont discussJson `json:"userJsonCont"` } -//评论人员json格式 +// 评论人员json格式 type discussJson struct { Numbers string `json:"numbers"` Name string `json:"name"` diff --git a/api/v1/assessment/assesshandle.go b/api/v1/assessment/assesshandle.go index 0e06ce5..3f42bb2 100644 --- a/api/v1/assessment/assesshandle.go +++ b/api/v1/assessment/assesshandle.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -90,7 +90,7 @@ func (d *DutyHandle) AssEssList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加考核项目 +// 添加考核项目 func (d *DutyHandle) AddAssEssInfo(c *gin.Context) { var requestData addAssEssInfo err := c.ShouldBindJSON(&requestData) @@ -156,7 +156,7 @@ func (d *DutyHandle) AddAssEssInfo(c *gin.Context) { } } -//获取考核项目详细内容 +// 获取考核项目详细内容 func (d *DutyHandle) GetAssEssInfo(c *gin.Context) { var requestData commonus.SetId err := c.ShouldBindJSON(&requestData) @@ -191,7 +191,7 @@ func (d *DutyHandle) GetAssEssInfo(c *gin.Context) { } -//修改考核项目内容 +// 修改考核项目内容 func (d *DutyHandle) EiteAssEssInfo(c *gin.Context) { var requestData eiteAssEssCont err := c.ShouldBindJSON(&requestData) @@ -264,7 +264,7 @@ func (d *DutyHandle) EiteAssEssInfo(c *gin.Context) { response.Result(0, saveData, "修改成功!", c) } -//考核项目编辑操作 +// 考核项目编辑操作 func eiteAssEssInfoCont(saveId int64, modelInfo assessmentmodel.AssessMentitems, saveData map[string]interface{}) (isTrue bool, dutyClassInfoErr error) { isTrue = false dutyClassInfoErr = global.GVA_DB_Performanceappraisal.Model(&modelInfo).Where("ai_id = ?", saveId).Updates(saveData).Error @@ -275,7 +275,7 @@ func eiteAssEssInfoCont(saveId int64, modelInfo assessmentmodel.AssessMentitems, return } -//修改考核项目的状态 +// 修改考核项目的状态 func (d *DutyHandle) EiteAssEssState(c *gin.Context) { var requestData dutyClassState err := c.ShouldBindJSON(&requestData) @@ -326,7 +326,7 @@ func (d *DutyHandle) EiteAssEssState(c *gin.Context) { } } -//获取职责类别内容 +// 获取职责类别内容 func GetAssEssCont(id int64) (isTrue bool, ContInfo assessmentmodel.AssessMentitems) { isTrue = false err := global.GVA_DB_Performanceappraisal.Where("ai_id = ?", id).First(&ContInfo).Error @@ -336,7 +336,7 @@ func GetAssEssCont(id int64) (isTrue bool, ContInfo assessmentmodel.AssessMentit return } -//获取职责项目及类别 +// 获取职责项目及类别 func GetAssessClass(id int64) (istrue bool, sssessClass assessmentmodel.AssessClass) { istrue = false assessErr := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.AssessMentitems{}).Select("assessmentitems.*,dutyclass.*").Joins("left join dutyclass on dutyclass.id = assessmentitems.ai_parent").Where("`ai_id` = ?", id).First(&sssessClass).Error diff --git a/api/v1/assessment/department_target.go b/api/v1/assessment/department_target.go index 34b2d46..cadc745 100644 --- a/api/v1/assessment/department_target.go +++ b/api/v1/assessment/department_target.go @@ -6,17 +6,17 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) -//部门考核 +// 部门考核 func (d *DutyHandle) DepartmentList(c *gin.Context) { var requestData rationSelect c.ShouldBindJSON(&requestData) @@ -73,7 +73,7 @@ func (d *DutyHandle) DepartmentListOld(c *gin.Context) { response.Result(0, departAryList, "数据获取成功!", c) } -//获取部门考核维度 +// 获取部门考核维度 func getDepartDimension(groupId, departId int64) (dimensionAry []departmentDimension) { var fileAry []int64 dimErr := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.DepartmentDimension{}).Select("dd_dimension").Where("`dd_group` = ? AND `dd_department` = ?", groupId, departId).Group("dd_dimension").Find(&fileAry).Error @@ -95,7 +95,7 @@ func getDepartDimension(groupId, departId int64) (dimensionAry []departmentDimen return } -//部门考核项目 +// 部门考核项目 func targetRationDepartList(groupID, departmentID, dimension int64) (contentList []taskDetails) { var fileTargetAry []assessmentmodel.QualitativeEvaluation listTargetErr := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Where("`qe_group` = ? AND `qe_accept_evaluation` = ? AND `qe_dimension` = ?", groupID, departmentID, dimension).Find(&fileTargetAry).Error @@ -121,7 +121,6 @@ func targetRationDepartList(groupID, departmentID, dimension int64) (contentList return } -// func (d *DutyHandle) DepartmentTaskList(c *gin.Context) { var requestData DelQualitative c.ShouldBindJSON(&requestData) @@ -246,7 +245,7 @@ func (d *DutyHandle) DepartmentTaskList(c *gin.Context) { response.Result(0, uotContAry, "数据获取成功!", c) } -//获取方案考核细则内容 +// 获取方案考核细则内容 func (d *DutyHandle) DetailsAssessmentScheme(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -326,7 +325,7 @@ func (d *DutyHandle) DetailsAssessmentScheme(c *gin.Context) { response.Result(0, uotCont, "数据获取成功!", c) } -//删除考核细则方案内容 +// 删除考核细则方案内容 func (d *DutyHandle) DelDepartmentTaskList(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -371,7 +370,7 @@ func (d *DutyHandle) DelDepartmentTaskList(c *gin.Context) { } } -//修改考核方案单条考核细则 +// 修改考核方案单条考核细则 func (d *DutyHandle) EiteOneQualitativeEvaluation(c *gin.Context) { var requestData EiteOneQualEval err := c.ShouldBindJSON(&requestData) @@ -421,7 +420,7 @@ func (d *DutyHandle) EiteOneQualitativeEvaluation(c *gin.Context) { } } -//编辑职务数据处理 +// 编辑职务数据处理 func eiteOneQuaEvaInfo(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Where("`qe_id` = ?", saveId).Updates(saveData).Error @@ -432,7 +431,7 @@ func eiteOneQuaEvaInfo(saveId int64, saveData map[string]interface{}) (isTrue bo return } -//获取定性考核指标对应的结构树 +// 获取定性考核指标对应的结构树 func (d *DutyHandle) QualEvalTargetTree(c *gin.Context) { var requestData QualEvalTargetTreeDies err := c.ShouldBindJSON(&requestData) @@ -540,7 +539,7 @@ func (d *DutyHandle) QualEvalTargetTree(c *gin.Context) { response.Result(0, uotContAry, "数据获取成功!", c) } -//部门考核(新) +// 部门考核(新) func (d *DutyHandle) DepartmentListNew(c *gin.Context) { var requestData rationSelect c.ShouldBindJSON(&requestData) @@ -569,7 +568,7 @@ func (d *DutyHandle) DepartmentListNew(c *gin.Context) { response.Result(0, departAryList, "数据获取成功!", c) } -//获取考核指标 +// 获取考核指标 func GetEvalTarget(dimId int64, group, departId string) (dimensionAry []taskDetailsLinkage) { var contAry []assessmentmodel.EvaluationTarget gormDb := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.EvaluationTarget{}).Where("et_state = 1 AND `et_dimension` = ?", dimId) @@ -615,7 +614,7 @@ func GetEvalTarget(dimId int64, group, departId string) (dimensionAry []taskDeta return } -//计算该指定部门维度指标下的分值 +// 计算该指定部门维度指标下的分值 func GetDepartDimTargetScore(group, depert string, dimeid, targetid int64) (scoreAll int64) { err := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Where("`qe_group` = ? AND `qe_accept_evaluation` = ? AND `qe_dimension` = ? AND `qe_target` = ? AND qe_state = 1", group, depert, dimeid, targetid).Pluck("COALESCE(SUM(qe_reference_score), 0) as rescore", &scoreAll).Error @@ -625,7 +624,7 @@ func GetDepartDimTargetScore(group, depert string, dimeid, targetid int64) (scor return } -//部门添加考核方案NEw +// 部门添加考核方案NEw func (d *DutyHandle) AddDepartmentDutyInfo(c *gin.Context) { var requestData AddDutyNewContGroup err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/detailed_target.go b/api/v1/assessment/detailed_target.go index 09459ff..de6bfcc 100644 --- a/api/v1/assessment/detailed_target.go +++ b/api/v1/assessment/detailed_target.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -15,7 +15,7 @@ import ( 考核细则 */ -//添加定性指标子栏目 +// 添加定性指标子栏目 func (d *DutyHandle) AddDetailedTarget(c *gin.Context) { var requestData addDetailedTargetType err := c.ShouldBindJSON(&requestData) @@ -69,7 +69,7 @@ func (d *DutyHandle) AddDetailedTarget(c *gin.Context) { } } -//获取考核细则详细内容 +// 获取考核细则详细内容 func (d *DutyHandle) GetDetailedTarget(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -108,7 +108,7 @@ func (d *DutyHandle) GetDetailedTarget(c *gin.Context) { response.Result(0, systemEvalCont, "数据获取成功!", c) } -//获取考核细则详细内容 +// 获取考核细则详细内容 func (d *DutyHandle) GetDetailedTargetList(c *gin.Context) { var requestData detailedTargetTypeList err := c.ShouldBindJSON(&requestData) @@ -170,7 +170,7 @@ func (d *DutyHandle) GetDetailedTargetList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//编辑考核细则数据处理 +// 编辑考核细则数据处理 func eiteDetailedTargetInfo(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.DetailedTarget{}).Where("`dt_id` = ?", saveId).Updates(saveData).Error @@ -181,7 +181,7 @@ func eiteDetailedTargetInfo(saveId int64, saveData map[string]interface{}) (isTr return } -//编辑考核细则内容 +// 编辑考核细则内容 func (d *DutyHandle) EiteDetailedTargetCont(c *gin.Context) { var requestData eitedetailedTargetCon err := c.ShouldBindJSON(&requestData) @@ -259,7 +259,7 @@ func (d *DutyHandle) EiteDetailedTargetCont(c *gin.Context) { } } -//删除考核细则 +// 删除考核细则 func (d *DutyHandle) DelDetailedTargetCont(c *gin.Context) { var requestData dutyClassState err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/dutyhandle.go b/api/v1/assessment/dutyhandle.go index 8b97a00..d2d32af 100644 --- a/api/v1/assessment/dutyhandle.go +++ b/api/v1/assessment/dutyhandle.go @@ -4,20 +4,20 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (d *DutyHandle) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "获取成功", c) } -//职责类别列表 +// 职责类别列表 func (d *DutyHandle) DutyClassList(c *gin.Context) { var requestData dutyClassRequest err := c.ShouldBindJSON(&requestData) @@ -82,7 +82,7 @@ func (d *DutyHandle) DutyClassList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//判断是否已经被使用 +// 判断是否已经被使用 func judgeIsTrue(classId int64) (isTrue int) { isTrue = 2 var evalTarCont []assessmentmodel.EvaluationTarget @@ -95,7 +95,7 @@ func judgeIsTrue(classId int64) (isTrue int) { return } -//添加职责类别 +// 添加职责类别 func (d *DutyHandle) AddDutyClass(c *gin.Context) { var requestData dutyClassAdd err := c.ShouldBindJSON(&requestData) @@ -136,7 +136,7 @@ func (d *DutyHandle) AddDutyClass(c *gin.Context) { } } -//查看职责类别详情 +// 查看职责类别详情 func (d *DutyHandle) GetDutyClassInfo(c *gin.Context) { var requestData commonus.SetId err := c.ShouldBindJSON(&requestData) @@ -163,7 +163,7 @@ func (d *DutyHandle) GetDutyClassInfo(c *gin.Context) { response.Result(0, dutyClassCont, "数据查询成功!", c) } -//修改职责类别内容 +// 修改职责类别内容 func (d *DutyHandle) EiteDutyClassInfo(c *gin.Context) { var requestData dutyClassEite err := c.ShouldBindJSON(&requestData) @@ -217,7 +217,7 @@ func (d *DutyHandle) EiteDutyClassInfo(c *gin.Context) { response.Result(0, eiteDutyClass, "数据编辑成功!", c) } -//状态变更及删除 +// 状态变更及删除 func (d *DutyHandle) StateDutyClass(c *gin.Context) { var requestData dutyClassState err := c.ShouldBindJSON(&requestData) @@ -265,7 +265,7 @@ func (d *DutyHandle) StateDutyClass(c *gin.Context) { } } -//状态软操作 +// 状态软操作 func dutyInfoStateSet(dutyClassInfo assessmentmodel.DutyClass, arrData dutyClassState) (isTrue bool, dutyClassInfoErr error) { isTrue = false //软处理 @@ -280,7 +280,7 @@ func dutyInfoStateSet(dutyClassInfo assessmentmodel.DutyClass, arrData dutyClass return } -//获取职责类别内容 +// 获取职责类别内容 func GetDutyClassCont(id int64) (isTrue bool, ContInfo assessmentmodel.DutyClass) { isTrue = false err := global.GVA_DB_Performanceappraisal.Where("id = ?", id).First(&ContInfo).Error diff --git a/api/v1/assessment/dutylist.go b/api/v1/assessment/dutylist.go index b3e5798..49407f9 100644 --- a/api/v1/assessment/dutylist.go +++ b/api/v1/assessment/dutylist.go @@ -4,15 +4,15 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//具体职责 +// 具体职责 func (d *DutyHandle) DutyList(c *gin.Context) { var requestData dutyRequest err := c.ShouldBindJSON(&requestData) @@ -113,7 +113,7 @@ func (d *DutyHandle) DutyList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加考核细则 +// 添加考核细则 func (d *DutyHandle) AddDutyInfo(c *gin.Context) { var requestData addDutyContent err := c.ShouldBindJSON(&requestData) @@ -191,7 +191,7 @@ func (d *DutyHandle) AddDutyInfo(c *gin.Context) { } } -//获取具体职责 +// 获取具体职责 func (d *DutyHandle) GetDutyInfo(c *gin.Context) { var requestData commonus.SetId err := c.ShouldBindJSON(&requestData) @@ -247,7 +247,7 @@ func (d *DutyHandle) GetDutyInfo(c *gin.Context) { response.Result(0, dutyOutInfo, "数据查询成功!", c) } -//编辑具体职责 +// 编辑具体职责 func (d *DutyHandle) EiteDutyInfor(c *gin.Context) { var requestData eiteDutyCont err := c.ShouldBindJSON(&requestData) @@ -322,7 +322,7 @@ func (d *DutyHandle) EiteDutyInfor(c *gin.Context) { response.Result(0, saveData, "修改成功!", c) } -//编辑具体职责内容 +// 编辑具体职责内容 func eiteDutyInfoCont(saveId int64, modelInfo assessmentmodel.DutyContent, saveData map[string]interface{}) (isTrue bool, dutyClassInfoErr error) { isTrue = false dutyClassInfoErr = global.GVA_DB_Performanceappraisal.Model(&modelInfo).Where("dc_id = ?", saveId).Updates(saveData).Error @@ -333,7 +333,7 @@ func eiteDutyInfoCont(saveId int64, modelInfo assessmentmodel.DutyContent, saveD return } -//修改考核项目的状态 +// 修改考核项目的状态 func (d *DutyHandle) EiteDutyState(c *gin.Context) { var requestData dutyClassState err := c.ShouldBindJSON(&requestData) @@ -384,7 +384,7 @@ func (d *DutyHandle) EiteDutyState(c *gin.Context) { } } -//获取职责类别内容 +// 获取职责类别内容 func GetDutyInfoCont(id int64) (isTrue bool, ContInfo assessmentmodel.DutyContent) { isTrue = false err := global.GVA_DB_Performanceappraisal.Where("dc_id = ?", id).First(&ContInfo).Error @@ -394,7 +394,7 @@ func GetDutyInfoCont(id int64) (isTrue bool, ContInfo assessmentmodel.DutyConten return } -//获取职责类别内容 +// 获取职责类别内容 func GetDutyInfoContAll(id int64) (isTrue bool, outAssDutyInfo outAessDuty) { isTrue = false var ContInfo dutyAssClass diff --git a/api/v1/assessment/dutytype.go b/api/v1/assessment/dutytype.go index 60b835d..60f3d2e 100644 --- a/api/v1/assessment/dutytype.go +++ b/api/v1/assessment/dutytype.go @@ -3,36 +3,36 @@ package assessment import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/assessmentmodel" ) -//协程设置 +// 协程设置 var syncProcess = sync.WaitGroup{} -//数据锁统计 +// 数据锁统计 type dataLockStatistics struct { dataMap []map[string]interface{} dataErrMap []map[string]interface{} mutext sync.RWMutex } -//读取锁数据 +// 读取锁数据 func (d *dataLockStatistics) readMyDayData() ([]map[string]interface{}, []map[string]interface{}) { d.mutext.RLock() defer d.mutext.RUnlock() return d.dataMap, d.dataErrMap } -//职责考核 +// 职责考核 type DutyHandle struct{} -//字符串ID +// 字符串ID type OutIdStruct struct { OutId string `json:"outId"` } -//职责类别查询参数 +// 职责类别查询参数 type dutyClassRequest struct { commonus.PageSetLimt OutIdStruct @@ -40,34 +40,34 @@ type dutyClassRequest struct { State int `json:"state"` } -//职责类别输出 +// 职责类别输出 type dutyClassOutput struct { assessmentmodel.DutyClass OutIdStruct IsTrue int `json:"istrue"` } -//职责类别添加 +// 职责类别添加 type dutyClassAdd struct { Title string `json:"title"` Type int `json:"type"` //1:定性考核;2:定量考核 Sort int `json:"sort"` } -//职责类别修改 +// 职责类别修改 type dutyClassEite struct { commonus.SetId dutyClassAdd } -//状态修改 +// 状态修改 type dutyClassState struct { commonus.SetId State int `json:"state"` // 状态 IsDel int `json:"isdel"` // 是否强制删除 } -//考核项目查询参数 +// 考核项目查询参数 type assessRequest struct { commonus.PageSetLimt ParentId string `json:"parentId"` //父级 @@ -75,7 +75,7 @@ type assessRequest struct { State int `json:"state"` } -//考核项目输出 +// 考核项目输出 type assessOutput struct { assessmentmodel.AssessMentitems OutIdStruct @@ -83,7 +83,7 @@ type assessOutput struct { ParentTitle string `json:"parentTitle"` } -//添加考核项目内容 +// 添加考核项目内容 type addAssEssInfo struct { dutyClassAdd Content string `json:"content"` //描述 @@ -94,7 +94,7 @@ type addAssEssInfo struct { CycleAttr int `json:"cycleattr"` //辅助计数 } -//修改考核项目内容 +// 修改考核项目内容 type eiteAssEssCont struct { commonus.SetId dutyClassAdd @@ -106,7 +106,7 @@ type eiteAssEssCont struct { CycleAttr int `json:"cycleattr"` //辅助计数 } -//具体职责查询 +// 具体职责查询 type dutyRequest struct { commonus.PageSetLimt ParentId string `json:"parentId"` //父级 @@ -116,7 +116,7 @@ type dutyRequest struct { AssEssUserId string `json:"assessuserid"` } -//具体职责输出 +// 具体职责输出 type dutyOutput struct { assessmentmodel.DutyContent OutIdStruct @@ -133,7 +133,7 @@ type dutyOutput struct { Content string `json:"contenting"` //描述 } -//添加具体职责 +// 添加具体职责 type addDutyContent struct { dutyClassAdd Type int `json:"type"` //1:定量考核;2:定性考核 @@ -146,7 +146,7 @@ type addDutyContent struct { Content string `json:"content"` //描述 } -//编辑具体项目 +// 编辑具体项目 type eiteDutyCont struct { commonus.SetId dutyClassAdd @@ -160,13 +160,13 @@ type eiteDutyCont struct { Content string `json:"content"` //描述 } -//部门具体职责 +// 部门具体职责 type specificDutyRequest struct { commonus.PageSetLimt DepartmentId string `json:"departmentId"` //部门ID } -//部门具体职责输出 +// 部门具体职责输出 type specificDutyOut struct { assessmentmodel.DepartDuty OutIdStruct @@ -185,7 +185,7 @@ type specificDutyOut struct { GroupTitle string `json:"groupTitle"` //集团 } -//添加部门具体职责 +// 添加部门具体职责 type addSpecificDutyCont struct { ParentId string `json:"parentId"` //部门ID ClassId string `json:"classId"` //考核类别 @@ -201,7 +201,7 @@ type addDepartDutyCont struct { Score int64 `json:"score"` //分数 } -//编辑部门具体职责 +// 编辑部门具体职责 type eiteSpecificDutyCont struct { commonus.SetId ParentId string `json:"parentId"` //部门ID @@ -219,7 +219,7 @@ type eiteDepartDutyCont struct { Score int64 `json:"score"` //分数 } -//输出考核关系架构 +// 输出考核关系架构 type outAessDuty struct { ClassId int64 `json:"classId"` ClassTitle string `json:"classTitle"` @@ -228,7 +228,7 @@ type outAessDuty struct { DutyTitle string `json:"dutyTitle"` } -//具体职责项与考核项目,类别 +// 具体职责项与考核项目,类别 type dutyAssClass struct { Title string `json:"title" gorm:"column:dc_title;type:text;comment:具体职责"` PartId int64 `json:"partId" gorm:"column:dc_parent;type:bigint(20) unsigned;default:0;not null;comment:父级"` @@ -242,7 +242,7 @@ type dutyAssClass struct { */ type EvaluationScheme struct{} -//添加考核方案 +// 添加考核方案 type AddScheme struct { dutyClassAdd //标题 Group int64 `json:"group"` //集团 @@ -282,7 +282,7 @@ type listTarget struct { Dimension string `json:"dimension"` //维度 (待定是否使用) } -//添加指标 +// 添加指标 type addTargetType struct { Title string `json:"title"` Type int `json:"type"` //1:定性考核;2:定量考核 @@ -298,7 +298,7 @@ type addTargetType struct { ScoringMethod int `json:"scoringmethod"` //计分方式(1:自动;2:手动) } -//列表输出 +// 列表输出 type outTargetList struct { assessmentmodel.EvaluationTarget OutId string `json:"outid"` @@ -309,13 +309,13 @@ type outTargetList struct { VisibleRangeDepartMap []outTargetAttr `json:"visiblerangedepartmap"` //可见范围(分厂) } -//输出结构体 +// 输出结构体 type outTargetAttr struct { Key string `json:"key"` Title string `json:"title"` } -//详细内容输出 +// 详细内容输出 type outTargetInfo struct { assessmentmodel.EvaluationTarget GroupMap []string `json:"group"` @@ -326,7 +326,7 @@ type outTargetInfo struct { VisibleRangeDepartMap []string `json:"visiblerangedepartmap"` //可见范围(分厂) } -//指标内容修改 +// 指标内容修改 type eiteTargetTypeCont struct { commonus.SetId addTargetType @@ -340,14 +340,14 @@ type addAttTarget struct { ParentId string `json:"parentid"` } -//子栏目列表 +// 子栏目列表 type attTargetList struct { commonus.PageSetLimt addAttTarget State int `json:"state"` //状态(1:启用;2:禁用;3:删除) } -//子栏目列表输出 +// 子栏目列表输出 type attTargetListOut struct { assessmentmodel.QualitativeTarget ParentIdStr string `json:"parentidstr"` @@ -355,7 +355,7 @@ type attTargetListOut struct { OutId string `json:"outid"` } -//指标子栏目修改 +// 指标子栏目修改 type eiteAttTarget struct { commonus.SetId addAttTarget @@ -371,7 +371,7 @@ type addDetailedTargetType struct { ParentIdSun string `json:"parentidsun"` } -//考核细则输出 +// 考核细则输出 type outDetailedTargetType struct { assessmentmodel.DetailedTarget ParentIdStr string `json:"parentidstr"` @@ -381,14 +381,14 @@ type outDetailedTargetType struct { OutId string `json:"outid"` } -//考核细则列表 +// 考核细则列表 type detailedTargetTypeList struct { commonus.PageSetLimt addDetailedTargetType State int `json:"state"` //状态(1:启用;2:禁用;3:删除) } -//修改考核细则 +// 修改考核细则 type eitedetailedTargetCon struct { commonus.SetId addDetailedTargetType @@ -408,7 +408,7 @@ type AddQualEval struct { EvaluationList []QualEvalSunList `json:"evaluationlist"` //测评详情 } -//定性考核内容 +// 定性考核内容 type QualEvalSunList struct { DetailedTarget string `json:"id"` //考核细则 Title string `json:"title"` //指标说明 @@ -421,13 +421,13 @@ type QualEvalSunList struct { Operator []string `json:"userlist"` //考核执行人 } -//查询定性考核列表 +// 查询定性考核列表 type SelectQualEval struct { Group string `json:"group"` //归属集团 DepartmentId string `json:"parentid"` //接受考核部门 } -//定性考核列表输出 +// 定性考核列表输出 type QualEvalArrt struct { Id string `json:"id"` Name string `json:"name"` @@ -437,31 +437,31 @@ type QualEvalListOut struct { Child []QualEvalListOutDepart `json:"child"` //定性考核部门 } -//定性考核部门 +// 定性考核部门 type QualEvalListOutDepart struct { QualEvalArrt Child []DimensionList `json:"child"` //维度列表 } -//定性考核列表维度项目 +// 定性考核列表维度项目 type DimensionList struct { QualEvalArrt Child []TargetList `json:"child"` //定性指标 } -//定性指标 +// 定性指标 type TargetList struct { QualEvalArrt Child []TargetSunList `json:"child"` //定性指标子栏目 } -//定性指标子栏目 +// 定性指标子栏目 type TargetSunList struct { QualEvalArrt Child []taskDetails `json:"child"` //考核细则 } -//具体职责 +// 具体职责 type taskDetails struct { QualEvalArrt Content string `json:"content"` //指标说明 @@ -473,7 +473,7 @@ type taskDetails struct { QeId string `json:"qeid"` } -//具体职责输出 +// 具体职责输出 type taskDatalsContOut struct { Id int64 `json:"id" gorm:"column:qe_id;type:bigint(20) unsigned;not null;comment:Id;index"` DetailedTarget int64 `json:"detailedtarget" gorm:"column:qe_detailed_target;type:bigint(20) unsigned;default:0;not null;comment:考核细则"` @@ -484,38 +484,38 @@ type taskDatalsContOut struct { State int `json:"state" gorm:"column:qe_state;type:int(1) unsigned;default:1;not null;comment:状态(1:启用;2:禁用;3:删除)"` } -//定量指标 +// 定量指标 type QualEvalRationListOut struct { QualEvalArrt Child []QualEvalRationListOutDepart `json:"child"` //定量考核部门 } -//定量考核部门 +// 定量考核部门 type QualEvalRationListOutDepart struct { QualEvalArrt Child []DimensionRationList `json:"child"` //维度列表 } -//定量考核列表维度项目 +// 定量考核列表维度项目 type DimensionRationList struct { QualEvalArrt Child []taskDetails `json:"child"` //定量指标 } -//定量指标 +// 定量指标 type TargetRationList struct { QualEvalArrt Child []taskDetails `json:"child"` //定量指标子栏目 } -//获取相关任务目标 +// 获取相关任务目标 type taskTargetList struct { Type int `json:"type"` //1:定性考核;2:定量考核 Group string `json:"group"` //归属集团 DepartMent []string `json:"department"` } -//根据条件获取考核细则 +// 根据条件获取考核细则 type SelectTaskTarget struct { Type int `json:"type"` //1:定性考核;2:定量考核 TargetId string `json:"targetid"` @@ -533,7 +533,7 @@ type AddRationCont struct { RationList []rationList `json:"rationlist"` //考核明细列表 } -//定量考核明细 +// 定量考核明细 type rationList struct { Target string `json:"id"` //考核指标 DepartmentId string `json:"parentid"` //执行考核部门ID @@ -544,13 +544,13 @@ type rationList struct { Operator []string `json:"userlist"` //考核执行人 } -//定量考核列表查询 +// 定量考核列表查询 type rationSelect struct { Group string `json:"group"` //归属集团 DepartmentId string `json:"parentid"` //接受考核部门 } -//部门考核 +// 部门考核 type deparMentModelOld struct { Id int64 `json:"id" gorm:"column:bf_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:bf_name;type:varchar(30);not null;comment:分厂名称"` //'分厂名称', @@ -562,13 +562,13 @@ type deparMentModel struct { WechatId int `json:"wechatid" gorm:"column:wechat_organization_id;type:int(4) unsigned;default:0;not null;comment:对照微信id"` //'对照微信id', } -//部门考核输出列表 +// 部门考核输出列表 type departmentDuty struct { QualEvalArrt Child []departmentDimension `json:"child"` //考核细则 } -//部门考核维度输出列表 +// 部门考核维度输出列表 type departmentDimension struct { QualEvalArrt Content string `json:"content"` //说明 @@ -577,7 +577,7 @@ type departmentDimension struct { Child []taskDetails `json:"child"` //考核细则 } -//考核细则联动列表 +// 考核细则联动列表 type taskDetailsLinkage struct { QualEvalArrt Content string `json:"content"` //指标说明 @@ -591,7 +591,7 @@ type taskDetailsLinkage struct { IsTrue int `json:"istrue"` //是否允许修改 } -//添加定性考核权重 +// 添加定性考核权重 type addDepartmentDimensionWeight struct { Hierarchy int64 `json:"hierarchy"` //层级 Type int64 `json:"type"` //1:定性考核;2:定量考核 @@ -602,7 +602,7 @@ type addDepartmentDimensionWeight struct { Weight int64 `json:"weight"` //权重 } -//批量添加指标权重 +// 批量添加指标权重 type addDepartDimensionWeightAry struct { // Hierarchy int64 `json:"hierarchy"` //层级 Type int64 `json:"type"` //1:定性考核;2:定量考核 @@ -616,7 +616,7 @@ type targetListType struct { Weight int64 `json:"weight"` //权重 } -//批量添加维度权重 +// 批量添加维度权重 type addDepartDimenWeightAry struct { // Hierarchy int64 `json:"hierarchy"` //层级 Type int64 `json:"type"` //1:定性考核;2:定量考核 @@ -625,12 +625,12 @@ type addDepartDimenWeightAry struct { Dimension []targetListType `json:"dimension"` //维度 } -//获取定量考核相关列表 +// 获取定量考核相关列表 type getDaulEvalDuty struct { assessmentmodel.EvaluationTarget } -//获取部门考核指标详情 +// 获取部门考核指标详情 type QualitativeEite struct { Dimension string `json:"dimension"` //考核维度 Target string `json:"target"` //考核指标 @@ -639,7 +639,7 @@ type QualitativeEite struct { DepartmentId string `json:"departmentid"` //接受考核部门 } -//输出部门考核指标详情 +// 输出部门考核指标详情 type QualitativeEiteOut struct { Group string `json:"group"` //归属集团 DepartmentId string `json:"departmentid"` //接受考核部门 @@ -659,13 +659,13 @@ type DelQualitative struct { VersionNumber string `json:"versionnumber"` //版本号码 } -//根据条件获取组合指标新的输出模式 +// 根据条件获取组合指标新的输出模式 type GetTaskTargetNewList struct { assessmentmodel.EvaluationTarget ReportList []string `json:"reportlist"` //上报人 } -//考核方案细则列表输出 +// 考核方案细则列表输出 type TargetContOutCont struct { Id string `json:"id"` Type int `json:"type"` @@ -694,7 +694,7 @@ type TargetContOutCont struct { MinOrMaxScore string `json:"score"` //参考分值 } -//修改考核方案单条细则 +// 修改考核方案单条细则 type EiteOneQualEval struct { commonus.SetIds Content string `json:"content"` //指标说明 @@ -706,13 +706,13 @@ type EiteOneQualEval struct { Operator []string `json:"operator"` //执行人列表 } -//考核卡片添加 +// 考核卡片添加 type addAssEssCard struct { AddQualEval TargetSunTitle string `json:"targetsuntitle"` } -//定性考核指标对应的结构树参数 +// 定性考核指标对应的结构树参数 type QualEvalTargetTreeDies struct { Group string `json:"group"` //集团 DepartmentId string `json:"parentid"` //部门 @@ -720,7 +720,7 @@ type QualEvalTargetTreeDies struct { Target string `json:"target"` //指标 } -//添加部门考核项目新 +// 添加部门考核项目新 type AddDutyNewContGroup struct { Group string `json:"group"` //集团 DepartmentId string `json:"parentid"` //部门 @@ -734,7 +734,7 @@ type AddDutyNewCont struct { Child []EvaluPross `json:"child"` //考核细则 } -//指标 +// 指标 type EvaluPross struct { Id string `json:"id"` //维度ID Name string `json:"name"` @@ -749,13 +749,13 @@ type EvaluPross struct { Status int `json:"status"` } -//部门考核输出列表 +// 部门考核输出列表 type departmentDutyNew struct { QualEvalArrt Child []taskDetailsLinkage `json:"child"` //考核细则 } -//设定指标结算周期 +// 设定指标结算周期 type SetEvaluationObjectives struct { Year int64 `json:"year"` //年度 Group int64 `json:"group"` //集团 @@ -767,7 +767,7 @@ type SetEvaluationObjectives struct { CycleAdded []CycleAddedType `json:"cycleadded"` } -//周期列表 +// 周期列表 type CycleAddedType struct { Id int64 `json:"id"` Zeroprize float64 `json:"zeroprize"` //零奖值"` @@ -775,7 +775,7 @@ type CycleAddedType struct { Capping float64 `json:"capping"` //封顶值"` } -//添加 定性考核指标关系指定细则 +// 添加 定性考核指标关系指定细则 type DutyAssEssTarget struct { Id int64 `json:"id"` Operator []string `json:"operator"` //考核执行人 diff --git a/api/v1/assessment/newassessment.go b/api/v1/assessment/newassessment.go index 18b06ab..4cdc7cf 100644 --- a/api/v1/assessment/newassessment.go +++ b/api/v1/assessment/newassessment.go @@ -6,12 +6,12 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) -//添加卡片考核数据处理 +// 添加卡片考核数据处理 func (d *dataLockStatistics) AddCardAssEss(deparmentId string, addData AddQualEval) { d.mutext.Lock() defer d.mutext.Unlock() diff --git a/api/v1/assessment/programme.go b/api/v1/assessment/programme.go index 67b3a74..2a7ab28 100644 --- a/api/v1/assessment/programme.go +++ b/api/v1/assessment/programme.go @@ -6,10 +6,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -21,7 +21,7 @@ func (a *EvaluationScheme) Index(c *gin.Context) { response.Result(0, outPut, "测评方案获取成功", c) } -//添加考核方案 +// 添加考核方案 func (a *EvaluationScheme) AddEvaluationScheme(c *gin.Context) { var requestData AddScheme err := c.ShouldBindJSON(&requestData) @@ -85,7 +85,7 @@ func (a *EvaluationScheme) AddEvaluationScheme(c *gin.Context) { } -//并发写入考核方案 +// 并发写入考核方案 func (d *dataLockStatistics) addEvaluationSchemeHandel(departId int64, addData AddScheme) { d.mutext.Lock() defer d.mutext.Unlock() @@ -166,7 +166,7 @@ func (d *dataLockStatistics) addEvaluationSchemeHandel(departId int64, addData A syncProcess.Done() } -//判断要新增的考核细则 +// 判断要新增的考核细则 func (d *dataLockStatistics) NewsAddRules(parentId int64, dataAry []schemeContent) (rulesSaveData []map[string]interface{}, isTrue bool) { isTrue = false for _, val := range dataAry { diff --git a/api/v1/assessment/qualitative_evaluation.go b/api/v1/assessment/qualitative_evaluation.go index 443b3d5..1558f40 100644 --- a/api/v1/assessment/qualitative_evaluation.go +++ b/api/v1/assessment/qualitative_evaluation.go @@ -6,11 +6,11 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -179,7 +179,7 @@ func (d *dataLockStatistics) addQualEvalList(departmentId string, addData AddQua syncProcess.Done() } -//定性考核列表 +// 定性考核列表 func (d *DutyHandle) GetQualEvalList(c *gin.Context) { var requestData SelectQualEval c.ShouldBindJSON(&requestData) @@ -225,7 +225,7 @@ func (d *DutyHandle) GetQualEvalList(c *gin.Context) { response.Result(0, aualEvalArrtAry, "查询完成!", c) } -//归档部门 +// 归档部门 func deparmentList(groupID int64, departmentIDStr string) (contentList []QualEvalListOutDepart, isTrue bool) { isTrue = false gormDbDepart := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Select("qe_accept_evaluation").Where("qe_type = 1 AND `qe_group` = ?", groupID).Group("qe_accept_evaluation") @@ -265,7 +265,7 @@ func deparmentList(groupID int64, departmentIDStr string) (contentList []QualEva return } -//归档维度 +// 归档维度 func dimensionList(groupID, departmentID int64) (contentList []DimensionList, isTrue bool) { isTrue = false var fileDimensionAry []int64 @@ -294,7 +294,7 @@ func dimensionList(groupID, departmentID int64) (contentList []DimensionList, is return } -//查询归档定性指标 +// 查询归档定性指标 func targetList(groupID, departmentID, dimension int64) (contentList []TargetList, isTrue bool) { isTrue = false var fileTargetAry []int64 @@ -323,7 +323,7 @@ func targetList(groupID, departmentID, dimension int64) (contentList []TargetLis return } -//查询归档定性子栏目 +// 查询归档定性子栏目 func targetSunList(groupID, departmentID, dimension, targetId int64) (contentList []TargetSunList, isTrue bool) { isTrue = false var fileTargetSunAry []int64 @@ -351,7 +351,7 @@ func targetSunList(groupID, departmentID, dimension, targetId int64) (contentLis return } -//考核细则 +// 考核细则 func taskDetailsList(groupID, departmentID, dimension, targetId, targetSunId int64) (contentList []taskDetails, isTrue bool) { isTrue = false var taskDetailsCont []taskDatalsContOut @@ -382,7 +382,7 @@ func taskDetailsList(groupID, departmentID, dimension, targetId, targetSunId int return } -//获取考核指标 +// 获取考核指标 func (d *DutyHandle) GetTaskTarget(c *gin.Context) { var requestData taskTargetList err := c.ShouldBindJSON(&requestData) @@ -447,7 +447,7 @@ func (d *DutyHandle) GetTaskTarget(c *gin.Context) { response.Result(0, taskTargetNewOut, "数据获取成功!", c) } -//获取定性指标子栏目 +// 获取定性指标子栏目 func (d *DutyHandle) GetTaskTargetSun(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -474,7 +474,7 @@ func (d *DutyHandle) GetTaskTargetSun(c *gin.Context) { response.Result(0, contAry, "数据获取成功!", c) } -//根据条件获取考核详情 +// 根据条件获取考核详情 func (d *DutyHandle) GetTaskTargetContAry(c *gin.Context) { var requestData SelectTaskTarget err := c.ShouldBindJSON(&requestData) @@ -540,7 +540,7 @@ func (d *DutyHandle) GetTaskTargetContAry(c *gin.Context) { response.Result(0, outContList, "数据获取成功!", c) } -//添加定性考核权重 +// 添加定性考核权重 func (d *DutyHandle) AddQualEvalWeight(c *gin.Context) { var requestData addDepartmentDimensionWeight err := c.ShouldBindJSON(&requestData) @@ -621,7 +621,7 @@ func (d *DutyHandle) AddQualEvalWeight(c *gin.Context) { response.Result(0, saveData, "数据写入成功!", c) } -//批量添加指标权重 +// 批量添加指标权重 func (d *DutyHandle) AddQualEvalDimWeightBatch(c *gin.Context) { var requestData addDepartDimensionWeightAry err := c.ShouldBindJSON(&requestData) @@ -762,7 +762,7 @@ func (d *DutyHandle) AddQualEvalDimWeightBatch(c *gin.Context) { response.Result(0, sumScore, "数据写入成功", c) } -//批量添加维度权重 +// 批量添加维度权重 func (d *DutyHandle) AddDimWeightBatch(c *gin.Context) { var requestData addDepartDimenWeightAry err := c.ShouldBindJSON(&requestData) @@ -847,7 +847,7 @@ func (d *DutyHandle) AddDimWeightBatch(c *gin.Context) { response.Result(0, depDimIdAry, "数据写入成功", c) } -//获取部门考核指标详情 +// 获取部门考核指标详情 func (d *DutyHandle) GetQualEval(c *gin.Context) { var requestData QualitativeEite err := c.ShouldBindJSON(&requestData) @@ -928,7 +928,7 @@ func (d *DutyHandle) GetQualEval(c *gin.Context) { response.Result(0, quaOutAry, "数据获取成功!", c) } -//修改定性考核内容 +// 修改定性考核内容 func (d *DutyHandle) EiteQualEvalCont(c *gin.Context) { var requestData QualitativeEiteOut err := c.ShouldBindJSON(&requestData) @@ -1104,7 +1104,7 @@ func (d *DutyHandle) EiteQualEvalCont(c *gin.Context) { } -//删除定性考核 +// 删除定性考核 func (d *DutyHandle) DelQualEvalCont(c *gin.Context) { var requestData DelQualitative err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/qualitative_target.go b/api/v1/assessment/qualitative_target.go index 69d9eef..07ad82c 100644 --- a/api/v1/assessment/qualitative_target.go +++ b/api/v1/assessment/qualitative_target.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -15,7 +15,7 @@ import ( 定性指标子栏目 */ -//添加定性指标子栏目 +// 添加定性指标子栏目 func (d *DutyHandle) AddQualitativeTarget(c *gin.Context) { var requestData addAttTarget err := c.ShouldBindJSON(&requestData) @@ -55,7 +55,7 @@ func (d *DutyHandle) AddQualitativeTarget(c *gin.Context) { } } -//获取定性指标子栏目列表 +// 获取定性指标子栏目列表 func (d *DutyHandle) GetQualitativeTargetList(c *gin.Context) { var requestData attTargetList err := c.ShouldBindJSON(&requestData) @@ -116,7 +116,7 @@ func (d *DutyHandle) GetQualitativeTargetList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//编辑指标数据处理 +// 编辑指标数据处理 func eiteQualTargetInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeTarget{}).Where("`q_id` = ?", saveId).Updates(saveData).Error @@ -127,7 +127,7 @@ func eiteQualTargetInfoes(saveId int64, saveData map[string]interface{}) (isTrue return } -//获取定性测评指标子栏目详细内容 +// 获取定性测评指标子栏目详细内容 func (d *DutyHandle) GetQualTargetInfo(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -160,7 +160,7 @@ func (d *DutyHandle) GetQualTargetInfo(c *gin.Context) { response.Result(0, systemEvalCont, "数据获取成功!", c) } -//修改定性指标子栏目 +// 修改定性指标子栏目 func (d *DutyHandle) EiteQualTargetInfo(c *gin.Context) { var requestData eiteAttTarget err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/ration_evaluation.go b/api/v1/assessment/ration_evaluation.go index aa2a065..405932b 100644 --- a/api/v1/assessment/ration_evaluation.go +++ b/api/v1/assessment/ration_evaluation.go @@ -6,12 +6,12 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) @@ -189,7 +189,7 @@ func (d *dataLockStatistics) addRationContList(deparmentId string, addData AddRa syncProcess.Done() } -//批量获取相关人员部门id +// 批量获取相关人员部门id func GetDepartmentByUserBast(userKey []string) (userDepartmentId []string) { if len(userKey) < 1 { return @@ -208,7 +208,7 @@ func GetDepartmentByUserBast(userKey []string) (userDepartmentId []string) { return } -//定量考核方案列表 +// 定量考核方案列表 func (d *DutyHandle) RationList(c *gin.Context) { var requestData rationSelect c.ShouldBindJSON(&requestData) @@ -253,7 +253,7 @@ func (d *DutyHandle) RationList(c *gin.Context) { response.Result(0, aualEvalArrtAry, "查询完成!", c) } -//归档部门 +// 归档部门 func deparmentRationList(groupID int64, departmentIDStr string) (contentList []QualEvalRationListOutDepart, isTrue bool) { isTrue = false gormDbDepart := global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.QualitativeEvaluation{}).Select("qe_accept_evaluation").Where("qe_type = 2 AND `qe_group` = ?", groupID).Group("qe_accept_evaluation") @@ -293,7 +293,7 @@ func deparmentRationList(groupID int64, departmentIDStr string) (contentList []Q return } -//归档维度 +// 归档维度 func dimensionRationList(groupID, departmentID int64) (contentList []DimensionRationList, isTrue bool) { isTrue = false var fileDimensionAry []int64 @@ -322,7 +322,7 @@ func dimensionRationList(groupID, departmentID int64) (contentList []DimensionRa return } -//查询归档定性指标 +// 查询归档定性指标 func targetRationList(groupID, departmentID, dimension int64) (contentList []taskDetails, isTrue bool) { isTrue = false var fileTargetAry []assessmentmodel.QualitativeEvaluation @@ -353,7 +353,7 @@ func targetRationList(groupID, departmentID, dimension int64) (contentList []tas return } -//删除定量考核 +// 删除定量考核 func (d *DutyHandle) DelRationList(c *gin.Context) { var requestData DelQualitative err := c.ShouldBindJSON(&requestData) @@ -390,7 +390,7 @@ func (d *DutyHandle) DelRationList(c *gin.Context) { } } -//获取定量考核 +// 获取定量考核 func (d *DutyHandle) GetRationList(c *gin.Context) { var requestData QualitativeEite err := c.ShouldBindJSON(&requestData) @@ -463,7 +463,7 @@ func (d *DutyHandle) GetRationList(c *gin.Context) { response.Result(0, quaOutAry, "数据获取成功!", c) } -//修改定量考核 +// 修改定量考核 func (d *DutyHandle) EiteRationList(c *gin.Context) { var requestData QualitativeEiteOut err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/set_evaluation_objectives.go b/api/v1/assessment/set_evaluation_objectives.go index 4613d1a..fb64dd7 100644 --- a/api/v1/assessment/set_evaluation_objectives.go +++ b/api/v1/assessment/set_evaluation_objectives.go @@ -4,10 +4,10 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/api/v1/assessment/specificduty.go b/api/v1/assessment/specificduty.go index 9421bb2..53c848e 100644 --- a/api/v1/assessment/specificduty.go +++ b/api/v1/assessment/specificduty.go @@ -4,16 +4,16 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/testpage" + "gin_server_admin/model/wechat" "github.com/gin-gonic/gin" ) -//具体部门职责 +// 具体部门职责 func (d *DutyHandle) SpecificDutyList(c *gin.Context) { var requestData specificDutyRequest err := c.ShouldBindJSON(&requestData) @@ -107,7 +107,7 @@ func (d *DutyHandle) SpecificDutyList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//添加具体职责 +// 添加具体职责 func (d *DutyHandle) AddSpecificDutyInfo(c *gin.Context) { var requestData addSpecificDutyCont err := c.ShouldBindJSON(&requestData) @@ -176,7 +176,7 @@ func (d *DutyHandle) AddSpecificDutyInfo(c *gin.Context) { } } -//添加部门具体职责 +// 添加部门具体职责 func (d *DutyHandle) AddDepartDutyInfo(c *gin.Context) { var requestData addDepartDutyCont err := c.ShouldBindJSON(&requestData) @@ -255,7 +255,7 @@ func (d *DutyHandle) AddDepartDutyInfo(c *gin.Context) { } } -//编辑具体内容 +// 编辑具体内容 func (d *DutyHandle) EiteDepartDutyInfo(c *gin.Context) { var requestData eiteDepartDutyCont err := c.ShouldBindJSON(&requestData) @@ -320,7 +320,7 @@ func (d *DutyHandle) EiteDepartDutyInfo(c *gin.Context) { } -//获取部门具体考核项目 +// 获取部门具体考核项目 func (d *DutyHandle) GetSpecDutyCont(c *gin.Context) { var requestData commonus.SetId err := c.ShouldBindJSON(&requestData) @@ -384,7 +384,7 @@ func (d *DutyHandle) GetSpecDutyCont(c *gin.Context) { response.Result(0, dutyOutInfo, "数据查询成功!", c) } -//获取集团信息 +// 获取集团信息 func GetGroupCont(id int64) (isTrue bool, ContInfo wechat.GroupForm) { isTrue = false err := global.GVA_DB_WatchDate.Where("g_id = ?", id).First(&ContInfo).Error @@ -394,7 +394,7 @@ func GetGroupCont(id int64) (isTrue bool, ContInfo wechat.GroupForm) { return } -//获得分厂名称 +// 获得分厂名称 func GetBranchFactory(id int64) (isTrue bool, ContInfo testpage.BranchFactory) { isTrue = false err := global.GVA_DB_Master.Where("bf_id = ?", id).First(&ContInfo).Error @@ -404,7 +404,7 @@ func GetBranchFactory(id int64) (isTrue bool, ContInfo testpage.BranchFactory) { return } -//编辑具体内容 +// 编辑具体内容 func (d *DutyHandle) EiteSpecFicDutyInfo(c *gin.Context) { var requestData eiteSpecificDutyCont err := c.ShouldBindJSON(&requestData) @@ -470,7 +470,7 @@ func (d *DutyHandle) EiteSpecFicDutyInfo(c *gin.Context) { } -//编辑具体职责内容 +// 编辑具体职责内容 func eiteSpecificDutyInfoCont(saveId int64, saveData map[string]interface{}) (isTrue bool, dutyClassInfoErr error) { var modelInfo assessmentmodel.DepartDuty isTrue = false @@ -482,7 +482,7 @@ func eiteSpecificDutyInfoCont(saveId int64, saveData map[string]interface{}) (is return } -//修改考核项目的状态 +// 修改考核项目的状态 func (d *DutyHandle) EiteSpecficDutyState(c *gin.Context) { var requestData dutyClassState err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/assessment/target.go b/api/v1/assessment/target.go index 321c0f2..044213e 100644 --- a/api/v1/assessment/target.go +++ b/api/v1/assessment/target.go @@ -7,12 +7,12 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) diff --git a/api/v1/autocode/autocodeExample.go b/api/v1/autocode/autocodeExample.go index ff83240..e22c729 100644 --- a/api/v1/autocode/autocodeExample.go +++ b/api/v1/autocode/autocodeExample.go @@ -1,12 +1,12 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - autocodeReq "github.com/flipped-aurora/gin-vue-admin/server/model/autocode/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/service" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/autocode" + autocodeReq "gin_server_admin/model/autocode/request" + "gin_server_admin/model/common/response" + "gin_server_admin/service" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/autocode/enter.go b/api/v1/autocode/enter.go index ea9dd21..d9ad7c9 100644 --- a/api/v1/autocode/enter.go +++ b/api/v1/autocode/enter.go @@ -1,7 +1,7 @@ package autocode type ApiGroup struct { - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. AutoCodeExampleApi - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. } diff --git a/api/v1/custom/customhandle.go b/api/v1/custom/customhandle.go index 3d66a4f..ea336e3 100644 --- a/api/v1/custom/customhandle.go +++ b/api/v1/custom/customhandle.go @@ -5,21 +5,21 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/api/admin/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/staff" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - roleModel "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/utils" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/api/admin/systemuser" + "gin_server_admin/api/v1/staff" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + systemReq "gin_server_admin/model/system/request" + roleModel "gin_server_admin/model/systemuser" + "gin_server_admin/utils" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" ) -//自定义登录 +// 自定义登录 func (cu *CustomHandle) CustomLogin(c *gin.Context) { var l systemReq.Login _ = c.ShouldBindJSON(&l) @@ -100,7 +100,7 @@ func (cu *CustomHandle) CustomLogin(c *gin.Context) { // } } -//自定义登录 +// 自定义登录 func (cu *CustomHandle) SystemLogin(c *gin.Context) { var l systemReq.Login _ = c.ShouldBindJSON(&l) @@ -212,7 +212,7 @@ func (cu *CustomHandle) SystemLogin(c *gin.Context) { // } } -//oauth2.0 +// oauth2.0 func (cu *CustomHandle) OauthTwo(c *gin.Context) { var requestData getData err := c.ShouldBindJSON(&requestData) @@ -251,7 +251,7 @@ func (cu *CustomHandle) OauthTwo(c *gin.Context) { } } -//企业微信单点登录 +// 企业微信单点登录 func (cu *CustomHandle) SingleSignOn(c *gin.Context) { var requestData oneLogin err := c.ShouldBindJSON(&requestData) @@ -343,7 +343,7 @@ func (cu *CustomHandle) SingleSignOn(c *gin.Context) { response.Result(0, saveData, "登录成功!", c) } -//一端登录 +// 一端登录 func (cu *CustomHandle) ScanCodeLogin(c *gin.Context) { var l systemReq.Login _ = c.ShouldBindJSON(&l) @@ -582,7 +582,7 @@ func (cu *CustomHandle) ScanCodeLogin(c *gin.Context) { } -//获取角色信息 +// 获取角色信息 func getRole(roleId int64) (roleCont roleModel.SystemRole) { global.GVA_DB_HrDataBase.Where("`id` = ?", roleId).Find(&roleCont) return diff --git a/api/v1/enter.go b/api/v1/enter.go index 8539346..f28b4e0 100644 --- a/api/v1/enter.go +++ b/api/v1/enter.go @@ -1,19 +1,19 @@ package v1 import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/archiveapi" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/assessment" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/custom" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/examination" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/example" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/examtestpage" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/fileuploaddownload" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/positionkpi" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/shiyan" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/staff" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/system" - "github.com/flipped-aurora/gin-vue-admin/server/api/v1/wechatcallback" + "gin_server_admin/api/v1/archiveapi" + "gin_server_admin/api/v1/assessment" + "gin_server_admin/api/v1/autocode" + "gin_server_admin/api/v1/custom" + "gin_server_admin/api/v1/examination" + "gin_server_admin/api/v1/example" + "gin_server_admin/api/v1/examtestpage" + "gin_server_admin/api/v1/fileuploaddownload" + "gin_server_admin/api/v1/positionkpi" + "gin_server_admin/api/v1/shiyan" + "gin_server_admin/api/v1/staff" + "gin_server_admin/api/v1/system" + "gin_server_admin/api/v1/wechatcallback" ) type ApiGroup struct { diff --git a/api/v1/examination/exampage.go b/api/v1/examination/exampage.go index 22396ff..85b2211 100644 --- a/api/v1/examination/exampage.go +++ b/api/v1/examination/exampage.go @@ -1,15 +1,15 @@ package examination import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//考试相关 +// 考试相关 type ExaminationPage struct{} -//首页 +// 首页 func (e *ExaminationPage) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "试卷获取成功", c) diff --git a/api/v1/examination/testquestions.go b/api/v1/examination/testquestions.go index c46a7dd..98af39e 100644 --- a/api/v1/examination/testquestions.go +++ b/api/v1/examination/testquestions.go @@ -1,15 +1,15 @@ package examination import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//试题相关操作 +// 试题相关操作 type TestQuestions struct{} -//首页 +// 首页 func (e *TestQuestions) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "试题获取成功", c) diff --git a/api/v1/example/enter.go b/api/v1/example/enter.go index 9149e02..2667b74 100644 --- a/api/v1/example/enter.go +++ b/api/v1/example/enter.go @@ -1,6 +1,6 @@ package example -import "github.com/flipped-aurora/gin-vue-admin/server/service" +import "gin_server_admin/service" type ApiGroup struct { CustomerApi diff --git a/api/v1/example/exa_breakpoint_continue.go b/api/v1/example/exa_breakpoint_continue.go index cf20d55..2bb2db4 100644 --- a/api/v1/example/exa_breakpoint_continue.go +++ b/api/v1/example/exa_breakpoint_continue.go @@ -6,10 +6,10 @@ import ( "mime/multipart" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - exampleRes "github.com/flipped-aurora/gin-vue-admin/server/model/example/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + exampleRes "gin_server_admin/model/example/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/example/exa_customer.go b/api/v1/example/exa_customer.go index 3939ebf..b6f6b3b 100644 --- a/api/v1/example/exa_customer.go +++ b/api/v1/example/exa_customer.go @@ -1,12 +1,12 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - exampleRes "github.com/flipped-aurora/gin-vue-admin/server/model/example/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/example" + exampleRes "gin_server_admin/model/example/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/example/exa_excel.go b/api/v1/example/exa_excel.go index 12dc2b9..6e00adc 100644 --- a/api/v1/example/exa_excel.go +++ b/api/v1/example/exa_excel.go @@ -1,10 +1,10 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/example" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/example/exa_file_upload_download.go b/api/v1/example/exa_file_upload_download.go index 5fdf6dc..dd3f737 100644 --- a/api/v1/example/exa_file_upload_download.go +++ b/api/v1/example/exa_file_upload_download.go @@ -1,11 +1,11 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - exampleRes "github.com/flipped-aurora/gin-vue-admin/server/model/example/response" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/example" + exampleRes "gin_server_admin/model/example/response" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/examtestpage/examtype.go b/api/v1/examtestpage/examtype.go index 28b1607..5802582 100644 --- a/api/v1/examtestpage/examtype.go +++ b/api/v1/examtestpage/examtype.go @@ -1,16 +1,16 @@ package examtestpage import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/model/hrsystem" ) -//获取集团架构参数 +// 获取集团架构参数 type getGroupType struct { Parentid int64 `json:"parentid"` } -//获取集团及分厂架构 +// 获取集团及分厂架构 type getGroupDepart struct { Id int64 `json:"id"` IdStr string `json:"idstr"` @@ -18,7 +18,7 @@ type getGroupDepart struct { All int `json:"all"` } -//组织架构员工对照表 +// 组织架构员工对照表 type groupRequest struct { GroupId int64 `json:"groupId"` } @@ -29,7 +29,7 @@ type groupUser struct { Children []groupUser `json:"groupUser"` } -//健康上报查询 +// 健康上报查询 type QueryHealthReportType struct { commonus.PageSetLimt StartTime string `json:"starttime"` @@ -41,7 +41,7 @@ type OutGovCont struct { Level int64 `json:"level" gorm:"column:level;type:int(5) unsigned;default:1;not null;comment:级别"` } -//Hr系统组织架构 +// Hr系统组织架构 type outGov struct { ID int64 `json:"id"` Name string `json:"name"` @@ -64,7 +64,7 @@ type govThree struct { Child []govThree `json:"children"` } -//部门数组 +// 部门数组 type govDepart struct { ID int64 `json:"id"` Name string `json:"name"` diff --git a/api/v1/examtestpage/grouphandle.go b/api/v1/examtestpage/grouphandle.go index 45f51ed..aacfc85 100644 --- a/api/v1/examtestpage/grouphandle.go +++ b/api/v1/examtestpage/grouphandle.go @@ -7,21 +7,21 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/testpage" + "gin_server_admin/model/wechat" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" "gorm.io/gorm" ) -//集团分厂管理模块 +// 集团分厂管理模块 type GroupHandleApi struct{} -//集团栏目 +// 集团栏目 type GroupMap struct { Id int64 `json:"id" gorm:"column:g_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:g_name;type:varchar(255);not null;comment:组织名称"` //'组织名称', @@ -46,13 +46,13 @@ type TableData struct { ErgodicID string `json:"ergodicid"` } -//POST提交参数 +// POST提交参数 type postGroupCanshu struct { Id int64 `json:"id" from:"id"` TypeId int `json:"typeid" from:"typeid"` } -//集团列表 +// 集团列表 func (g *GroupHandleApi) GroupList(c *gin.Context) { var groupStruct []wechat.GroupForm //集团表结构 gormDb := global.GVA_DB_WatchDate.Model(&groupStruct) @@ -176,7 +176,8 @@ func (g *GroupHandleApi) GetGroupInfo(c *gin.Context) { response.Result(0, groupStruct, "获取成功", c) } -/*获取子公司信息 +/* +获取子公司信息 @id 子公司ID */ func (g *GroupHandleApi) GetSubsidiaryInfo(c *gin.Context) { @@ -196,7 +197,8 @@ func (g *GroupHandleApi) GetSubsidiaryInfo(c *gin.Context) { response.Result(0, subsidiaryStruct, "获取成功", c) } -/*获取工段信息 +/* +获取工段信息 @id 工段ID */ func (g *GroupHandleApi) GetGroupPositionInfo(c *gin.Context) { @@ -421,12 +423,12 @@ func (g *GroupHandleApi) EiteGroupInfo(c *gin.Context) { response.Result(0, groupStruct, "修改成功", c) } -//获取单个成员信息 +// 获取单个成员信息 type getOneUserSendDate struct { UserId string `json:"userid" from:"userid"` } -//获取成员详细信息 +// 获取成员详细信息 func (g *GroupHandleApi) GetOneUserInfoAll(c *gin.Context) { var groupInfo getOneUserSendDate _ = c.ShouldBindJSON(&groupInfo) //获取提交的参数 @@ -469,13 +471,13 @@ func (g *GroupHandleApi) GetOneUserInfoAll(c *gin.Context) { } -//获取单个成员信息 +// 获取单个成员信息 type getDeparMentUserSendDate struct { Id int `json:"id" from:"id"` FetchChild int `json:"fetch_child" from:"fetch_child"` } -//获取部门成员 GetDepartmentUserList +// 获取部门成员 GetDepartmentUserList func (g *GroupHandleApi) GetDepartMentUserInfoAll(c *gin.Context) { var groupInfo getDeparMentUserSendDate _ = c.ShouldBindJSON(&groupInfo) //获取提交的参数 @@ -565,7 +567,7 @@ func (g *GroupHandleApi) GetDepartMentUserInfoAll(c *gin.Context) { } -//刷新集团成员数据库 +// 刷新集团成员数据库 func (g *GroupHandleApi) RefreshDataBaseUser(c *gin.Context) { var userAry []wechat.WechatUsers var weChatAry []commonus.UserListStruct @@ -860,7 +862,7 @@ func (g *GroupHandleApi) RefreshDataBaseUser(c *gin.Context) { } -//获取集团和分厂架构 +// 获取集团和分厂架构 func (g *GroupHandleApi) GetGroupDepartMap(c *gin.Context) { var requestData getGroupDepart c.ShouldBindJSON(&requestData) @@ -912,7 +914,7 @@ func (g *GroupHandleApi) GetGroupDepartMap(c *gin.Context) { response.Result(0, govMapThree, "获取成功", c) } -//递归树 +// 递归树 func GovThreeList(parentId int64, govAry []outGov) []govThree { var govMap []govThree for _, v := range govAry { @@ -981,7 +983,7 @@ func GovThreeList(parentId int64, govAry []outGov) []govThree { // response.Result(0, sendMap, "获取成功", c) // } -//获得分厂名称 +// 获得分厂名称 func GetBranchFactoryMap(id int64) (isTrue bool, ContInfo []testpage.BranchFactory) { isTrue = false err := global.GVA_DB_Master.Where("bf_group = ?", id).Find(&ContInfo).Error @@ -1020,7 +1022,7 @@ func GetBranchFactoryMapEs(id int64, jbq int) (isTrue bool, ContInfo []bfMapJbqL return } -//获取集团架构人员信息对照表 +// 获取集团架构人员信息对照表 func (g *GroupHandleApi) GetGroupUser(c *gin.Context) { var requestData getGroupDepart c.ShouldBindJSON(&requestData) @@ -1096,7 +1098,7 @@ func (g *GroupHandleApi) GetGroupUserOld(c *gin.Context) { response.Result(0, sendMap, "获取成功", c) } -//获取分厂与对应员工 +// 获取分厂与对应员工 func GetDepartMap(printId int64) (isTrue bool, departMap []groupUser) { isTrue = false var branchFactory []testpage.BranchFactory @@ -1118,7 +1120,7 @@ func GetDepartMap(printId int64) (isTrue bool, departMap []groupUser) { return } -//获取分厂人员列表 +// 获取分厂人员列表 func GetBranchFactoryUser(printId int64) (isTrue bool, departMap []groupUser) { isTrue = false var userInfo []testpage.PersonalDetails @@ -1142,7 +1144,7 @@ type departSelect struct { Id string `json:"id"` } -//获取分厂列表 +// 获取分厂列表 func (g *GroupHandleApi) GetDepartmentListOld(c *gin.Context) { var requestData commonus.SetIds err := c.ShouldBindJSON(&requestData) @@ -1169,7 +1171,7 @@ func (g *GroupHandleApi) GetDepartmentListOld(c *gin.Context) { response.Result(0, bfList, "数据获取成功!", c) } -//获取分厂列表 +// 获取分厂列表 func (g *GroupHandleApi) GetDepartmentList(c *gin.Context) { var requestData getGroupDepart c.ShouldBindJSON(&requestData) @@ -1219,7 +1221,7 @@ func (g *GroupHandleApi) GetDepartmentList(c *gin.Context) { response.Result(0, govMapThree, "获取成功", c) } -//递归树 +// 递归树 func GovDepartThreeList(parentId int64, govAry []govDepart) []govDepartThree { var govMap []govDepartThree for _, v := range govAry { @@ -1233,7 +1235,7 @@ func GovDepartThreeList(parentId int64, govAry []govDepart) []govDepartThree { return govMap } -//递归树 +// 递归树 func GovUserThreeList(parentId int64, govAry []govUserCont) []govUserContThree { // fmt.Printf("parentId---------->%v\n", parentId) var govMap []govUserContThree @@ -1248,7 +1250,7 @@ func GovUserThreeList(parentId int64, govAry []govUserCont) []govUserContThree { return govMap } -//获取Hr人员信息 +// 获取Hr人员信息 func getUserList(departmentId int64, level int) (userList []peopleList) { var userAry []hrsystem.PersonArchives gormDb := global.GVA_DB_HrDataBase.Model(&hrsystem.PersonArchives{}).Select("`id`,`number`,`name`,`wechat`,`work_wechat`,`key`").Where("state = 1 AND emp_type BETWEEN 1 AND 10 ") diff --git a/api/v1/examtestpage/healthreportstat.go b/api/v1/examtestpage/healthreportstat.go index e9288d1..937c865 100644 --- a/api/v1/examtestpage/healthreportstat.go +++ b/api/v1/examtestpage/healthreportstat.go @@ -8,15 +8,15 @@ import ( "sync" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/locationing" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/locationing" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" ) -//健康上报 +// 健康上报 type HealthReportStat struct{} func (h *HealthReportStat) HealthList(c *gin.Context) { @@ -45,7 +45,7 @@ func (h *HealthReportStat) HealthList(c *gin.Context) { response.Result(200, healthReportInfo, msg, c) } -//获取企业当前正在运行的上报任务ID列表 +// 获取企业当前正在运行的上报任务ID列表 func (h *HealthReportStat) RunHealthList(c *gin.Context) { var healthReport commonus.GetHealthReportRun err := c.ShouldBindJSON(&healthReport) @@ -70,7 +70,7 @@ func (h *HealthReportStat) RunHealthList(c *gin.Context) { response.Result(0, jobMap, msg, c) } -//获取健康上报任务详情 +// 获取健康上报任务详情 func (h *HealthReportStat) PostReportJobInfo(c *gin.Context) { var healthReportJob commonus.GetReportJobInfoDate err := c.ShouldBindJSON(&healthReportJob) @@ -94,7 +94,7 @@ func (h *HealthReportStat) PostReportJobInfo(c *gin.Context) { response.Result(0, strucr.JobInfo, msg, c) } -//获取用户填写答案列表 +// 获取用户填写答案列表 func (h *HealthReportStat) PostReportAnswerList(c *gin.Context) { var reportAnswer commonus.ReportAnswerStruct err := c.ShouldBindJSON(&reportAnswer) @@ -171,7 +171,7 @@ func (h *HealthReportStat) PostReportAnswerList(c *gin.Context) { //获取用户填写答案列表 (全部) -//用户填写 +// 用户填写 var myStatisWg = sync.WaitGroup{} type dataLockStatistics struct { @@ -180,7 +180,7 @@ type dataLockStatistics struct { mutext sync.RWMutex } -//读取锁数据 +// 读取锁数据 func (d *dataLockStatistics) readMyDayData() ([]map[string]interface{}, []map[string]interface{}) { d.mutext.RLock() defer d.mutext.RUnlock() @@ -277,7 +277,7 @@ func CalculationNotReport(time string, decisionTime int64, reportedPeople []map[ fmt.Printf("%v==================>%v", userDateCount, userCurlCount) } -//向相关人员发送警报 https://docu.hxgk.group/images/2021_11/205c2d8d35491880a1ac9f03d6e879d3.jpg +// 向相关人员发送警报 https://docu.hxgk.group/images/2021_11/205c2d8d35491880a1ac9f03d6e879d3.jpg func sendMessAgeAlarm(calCulTime int64, alarmUser []map[string]interface{}) (sendBakc map[string]interface{}) { // fmt.Printf("%v\n", reflect.TypeOf(alarmUser)) var sendText string @@ -361,7 +361,7 @@ func sendMessAgeAlarm(calCulTime int64, alarmUser []map[string]interface{}) (sen // fmt.Printf("%v---------------------->%v\n", sendText, sendText) } -//获取上报地址异常的数据人员信息 +// 获取上报地址异常的数据人员信息 func (d *dataLockStatistics) getUserAnswerList(jobid, tadayTime, calCulTime string, page int, pageSize int64, legalAreaList []locationing.LegalArea, regionalRiskLevel []commonus.RegionalRiskLevel, isRiskYes bool) { d.mutext.Lock() defer d.mutext.Unlock() @@ -564,7 +564,7 @@ func (d *dataLockStatistics) getUserAnswerList(jobid, tadayTime, calCulTime stri myStatisWg.Done() } -//添加报警信息通知人 +// 添加报警信息通知人 func (h *HealthReportStat) NoticeUserList(c *gin.Context) { // var reportAnswer commonus.GetHealthReportRun // err := c.ShouldBindJSON(&reportAnswer) @@ -581,7 +581,7 @@ func (h *HealthReportStat) NoticeUserList(c *gin.Context) { response.Result(0, noticeUserStruct, "获取到数据成功!", c) } -//添加报警人信息 +// 添加报警人信息 func (h *HealthReportStat) AddNoticeUser(c *gin.Context) { var reportAnswer locationing.NoticeUser err := c.ShouldBindJSON(&reportAnswer) @@ -613,7 +613,7 @@ func (h *HealthReportStat) AddNoticeUser(c *gin.Context) { response.Result(0, reportAnswer, "写入数据成功!", c) } -//修改报警人信息 +// 修改报警人信息 func (h *HealthReportStat) EiteNoticeUser(c *gin.Context) { var reportAnswer locationing.NoticeUser err := c.ShouldBindJSON(&reportAnswer) @@ -650,7 +650,7 @@ func (h *HealthReportStat) EiteNoticeUser(c *gin.Context) { response.Result(0, reportAnswer, "写入数据成功!", c) } -//删除报警人信息 +// 删除报警人信息 func (h *HealthReportStat) DelNoticeUser(c *gin.Context) { var reportAnswer locationing.NoticeUser err := c.ShouldBindJSON(&reportAnswer) @@ -670,7 +670,7 @@ func (h *HealthReportStat) DelNoticeUser(c *gin.Context) { response.Result(0, reportAnswer, "删除成功!", c) } -//根据ID查询详情 +// 根据ID查询详情 func (h *HealthReportStat) LookNoticeUser(c *gin.Context) { var reportAnswer locationing.NoticeUser err := c.ShouldBindJSON(&reportAnswer) @@ -769,7 +769,7 @@ func (h *HealthReportStat) PostReportAnswerListTodayAll(c *gin.Context) { } -//上报数据写入数据库 +// 上报数据写入数据库 func reportDataWrittenToDatabase(saveAry []map[string]interface{}) { if len(saveAry) > 0 { for intdx, val := range saveAry { diff --git a/api/v1/examtestpage/healthreportstathand.go b/api/v1/examtestpage/healthreportstathand.go index fbda156..3cce8b3 100644 --- a/api/v1/examtestpage/healthreportstathand.go +++ b/api/v1/examtestpage/healthreportstathand.go @@ -7,16 +7,16 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/location" - "github.com/flipped-aurora/gin-vue-admin/server/model/locationing" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/location" + "gin_server_admin/model/locationing" + "gin_server_admin/model/wechat" "github.com/gin-gonic/gin" ) -//健康上报列表 +// 健康上报列表 func (h *HealthReportStat) PostReportAnswerListLimit(c *gin.Context) { var reportAnswer commonus.ReportAnswerStruct err := c.ShouldBindJSON(&reportAnswer) @@ -209,7 +209,7 @@ func (h *HealthReportStat) PostReportAnswerListLimit(c *gin.Context) { } } -//向相关人员发送信息 +// 向相关人员发送信息 func (h *HealthReportStat) SendRelevantPersonnelMsg(c *gin.Context) { tadayTime := commonus.GetYesterDay() //获取昨日信息 calCulTime := commonus.DateToTimeStamp(tadayTime + " 12:00:00") @@ -246,7 +246,7 @@ func (h *HealthReportStat) SendRelevantPersonnelMsg(c *gin.Context) { } } -//返回结构体 +// 返回结构体 type ReportStructExce struct { Id int64 `json:"id"` Name string `json:"name"` @@ -261,7 +261,7 @@ type ReportStructExce struct { GroupId int64 `json:"groupid"` } -//上报统计 +// 上报统计 func (h *HealthReportStat) ReportStatistics(c *gin.Context) { var reportStatistics commonus.ReportStatisticsStruct err := c.ShouldBindJSON(&reportStatistics) @@ -376,7 +376,7 @@ func (h *HealthReportStat) ReportStatistics(c *gin.Context) { response.Result(0, returnData, "查询成功!", c) } -//未上报人员 +// 未上报人员 func (h *HealthReportStat) NotReportedPeople(c *gin.Context) { var reportAnswer commonus.ReportAnswerStruct err := c.ShouldBindJSON(&reportAnswer) @@ -436,7 +436,7 @@ func (h *HealthReportStat) NotReportedPeople(c *gin.Context) { response.Result(0, returnData, "未上报人员列表!", c) } -//获取全国风险地区列表(企鹅接口 https://view.inews.qq.com/g2/getOnsInfo?name=disease_h5) +// 获取全国风险地区列表(企鹅接口 https://view.inews.qq.com/g2/getOnsInfo?name=disease_h5) func (h *HealthReportStat) NationalRiskArea(c *gin.Context) { jsondata, isyes := commonus.GetNationalRiskArea() @@ -449,7 +449,7 @@ func (h *HealthReportStat) NationalRiskArea(c *gin.Context) { response.Result(0, returnData, "全国风险地区列表!", c) } -//测试写入异常人员 +// 测试写入异常人员 func (h *HealthReportStat) TestMan(c *gin.Context) { var reportAnswer location.AbnormalPeople c.ShouldBindJSON(&reportAnswer) @@ -459,7 +459,7 @@ func (h *HealthReportStat) TestMan(c *gin.Context) { response.Result(0, returnData, "全国风险地区列表!", c) } -//向相关人员发送信息 +// 向相关人员发送信息 func (h *HealthReportStat) SendRelevantPersonnelTodayMsg(c *gin.Context) { tadayTime := commonus.GetToDay() //获取昨日信息 calCulTime := commonus.DateToTimeStamp(tadayTime + " 09:00:00") @@ -500,7 +500,7 @@ func (h *HealthReportStat) SendRelevantPersonnelTodayMsg(c *gin.Context) { } } -//查询 +// 查询 func (h *HealthReportStat) QueryHealthReport(c *gin.Context) { var requestData QueryHealthReportType c.ShouldBindJSON(&requestData) diff --git a/api/v1/fileuploaddownload/fileupdowntype.go b/api/v1/fileuploaddownload/fileupdowntype.go index 027b266..f549cff 100644 --- a/api/v1/fileuploaddownload/fileupdowntype.go +++ b/api/v1/fileuploaddownload/fileupdowntype.go @@ -12,11 +12,11 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/commonus" + "gin_server_admin/global" ) -//上传文件返回前端 +// 上传文件返回前端 type UpLoadFileStruct struct { ID int64 `json:"ID"` Key string `json:"key"` @@ -31,20 +31,20 @@ type UpLoadFileStruct struct { Size string `json:"size"` } -//文件基本属性 +// 文件基本属性 type FileAttribute struct { FileName string `json:"fileName"` FileSize int64 `json:"fileSize"` FileExt string `json:"fileExt"` } -//远程数据返回 +// 远程数据返回 type CallBackFileData struct { commonus.ReturnJson Data RemoteUploadDataStruct `json:data` } -//远程上传返回 +// 远程上传返回 type RemoteUploadDataStruct struct { Callbackurl string `json:"callbackurl"` //预览地址 FilePath string `json:"filePath"` //物理地址 @@ -57,7 +57,7 @@ type RemoteUploadDataStruct struct { } -//上传到远程服务器 +// 上传到远程服务器 func postFormDataWithSingleFile(filePath string, fileType int) (CallBackFileData CallBackFileData) { client := http.Client{} bodyBuf := &bytes.Buffer{} diff --git a/api/v1/fileuploaddownload/fileuploaddown.go b/api/v1/fileuploaddownload/fileuploaddown.go index edd1aca..75a2300 100644 --- a/api/v1/fileuploaddownload/fileuploaddown.go +++ b/api/v1/fileuploaddownload/fileuploaddown.go @@ -7,8 +7,8 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -19,7 +19,7 @@ type urlData struct { Sign string `json:"sign"` } -//上传文件(远程) +// 上传文件(远程) func (f *FileUploadDownload) LongRangeFileUpload(c *gin.Context) { _, fileHeader, fileErr := c.Request.FormFile("file") typePostForm := c.PostForm("type") diff --git a/api/v1/positionkpi/entry.go b/api/v1/positionkpi/entry.go index a67d679..c8ddf22 100644 --- a/api/v1/positionkpi/entry.go +++ b/api/v1/positionkpi/entry.go @@ -1,8 +1,8 @@ package positionkpi import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/commonus" + "gin_server_admin/model/assessmentmodel" ) type ApiGroup struct { diff --git a/api/v1/positionkpi/posttarget.go b/api/v1/positionkpi/posttarget.go index 5356bcb..ad41e22 100644 --- a/api/v1/positionkpi/posttarget.go +++ b/api/v1/positionkpi/posttarget.go @@ -5,11 +5,11 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) diff --git a/api/v1/positionkpi/posttargetcont.go b/api/v1/positionkpi/posttargetcont.go index e240602..72b37a8 100644 --- a/api/v1/positionkpi/posttargetcont.go +++ b/api/v1/positionkpi/posttargetcont.go @@ -6,11 +6,11 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) diff --git a/api/v1/shiyan/enter.go b/api/v1/shiyan/enter.go index 2e1a4f0..e0d866c 100644 --- a/api/v1/shiyan/enter.go +++ b/api/v1/shiyan/enter.go @@ -3,26 +3,26 @@ package shiyan import ( "sync" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/model/hrsystem" ) var synPro = sync.WaitGroup{} type ApiGroup struct { - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. ShiyanApi - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. } -//输出迁移组织架构 +// 输出迁移组织架构 type outOrgCont struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Superior int64 `json:"superior" gorm:"column:superior;type:bigint(20) unsigned;default:0;not null;comment:上级ID"` OrganizationType int64 `json:"organizationtype" gorm:"column:organization_type;type:bigint(20) unsigned;default:0;not null;comment:行政组织类型"` } -//职务相关 +// 职务相关 type jobAttber struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Number string `json:"number" gorm:"column:number;type:varchar(255) unsigned;default:'';not null;comment:编号"` @@ -35,18 +35,18 @@ type jobAttber struct { JobName string `json:"jobname" gorm:"column:jobname;type:varchar(255) unsigned;default:'';not null;comment:职务分类名称"` } -//删除提交指标数据 +// 删除提交指标数据 type delTargetStr struct { commonus.SetIds UserKey string `json:"userkey"` } -//更具提交人删除定量信息 +// 更具提交人删除定量信息 type basisType struct { UserKey string `json:"userkey"` } -//定量流水全奖值、零奖值、封顶值 +// 定量流水全奖值、零奖值、封顶值 type FlowLogAllZreo struct { Id string `json:"id"` TargetId string `json:"targetid"` //指标ID` @@ -85,7 +85,7 @@ type AddDutyNewCont struct { Child []EvaluPross `json:"child"` //考核细则 } -//指标 +// 指标 type EvaluPross struct { Id string `json:"id"` //维度ID Name string `json:"name"` @@ -100,7 +100,7 @@ type EvaluPross struct { Status int `json:"status"` } -//行政组织树查询 +// 行政组织树查询 type govThreeType struct { Id int64 `json:"id"` IdStr string `json:"idstr"` @@ -109,14 +109,14 @@ type govThreeType struct { type MenuList []OutGovCont -//输出行政组织信息 +// 输出行政组织信息 type OutGovCont struct { hrsystem.AdministrativeOrganization ClassName string `json:"classname" gorm:"column:classname;type:varchar(255) unsigned;default:'';not null;comment:行政组织分类名称"` Level int64 `json:"level" gorm:"column:level;type:int(5) unsigned;default:1;not null;comment:级别"` } -//组织架构树 +// 组织架构树 type govThree struct { OutGovCont Child []govThree `json:"child"` diff --git a/api/v1/shiyan/shiyan.go b/api/v1/shiyan/shiyan.go index ca141c6..64131ea 100644 --- a/api/v1/shiyan/shiyan.go +++ b/api/v1/shiyan/shiyan.go @@ -10,16 +10,16 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/textcomparison" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/approvalprocess" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/api/textcomparison" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/approvalprocess" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/wechat" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" "github.com/mitchellh/mapstructure" ) @@ -1412,42 +1412,42 @@ func DelteGroup(group, depart, dime, target, suntar, detaid int64, runDepart str // 文本实验 textcomparison func (s *ShiyanApi) TextShiyan(c *gin.Context) { - participle := textcomparison.NewGoJieba() - //去除文本Html标签 - srcStr := textcomparison.RemoveHtml("关于区块链和数字货币的关系,很多人或多或少都存在疑惑。简单来说,区块链是比特币的底层运用,而比特币只是区块链的一个小应用而已。" + - "数字货币即虚拟货币,最早的数字货币诞生于2009年,其发明者中本聪为了应对经济危机对于实体货币经济的冲击。比特币是最早的数字货币,后来出现了以太币、火币以及莱特币等虚拟货币,这些虚拟货币是不能用来交易的。" + - "狭义来讲,区块链是一种按照时间顺序将数据区块以顺序相连的方式组合成的一种链式数据结构, 并以密码学方式保证的不可篡改和不可伪造的分布式账本。" + - "广义来讲,区块链技术是利用块链式数据结构来验证与存储数据、利用分布式节点共识算法来生成和更新数据、利用密码学的方式保证数据传输和访问的安全、利用由自动化脚本代码组成的智能合约来编程和操作数据的一种全新的分布式基础架构与计算方式。") - dstStr := textcomparison.RemoveHtml("区块链技术为我们的信息防伪与数据追踪提供了革新手段。区块链中的数据区块顺序相连构成了一个不可篡改的数据链条,时间戳为所有的交易行为贴上了一套不讲课伪造的真是标签,这对于人们在现实生活中打击假冒伪劣产品大有裨益; " + - "市场分析指出,整体而言,区块链技术目前在十大金融领域显示出应用前景,分别是资产证券化、保险、供应链金融、场外市场、资产托管、大宗商品交易、风险信息共享机制、贸易融资、银团贷款、股权交易交割。" + - "这些金融场景有三大共性:参与节点多、验真成本高、交易流程长,而区块链的分布式记账、不可篡改、内置合约等特性可以为这些金融业务中的痛点提供解决方案。" + - "传统的工业互联网模式是由一个中心化的机构收集和管理所有的数据信息,容易产生因设备生命周期和安全等方面的缺陷引起的数据丢失、篡改等问题。区块链技术可以在无需任何信任单个节点的同时构建整个网络的信任共识,从而很好的解决目前工业互联网技术领域的一些缺陷,让物与物之间能够实现更好的连接.") - - srcWordsWeight := participle.C.ExtractWithWeight(srcStr, 30) - dstWordsWeight := participle.C.ExtractWithWeight(dstStr, 30) - fmt.Printf("srcWordsWeight: %v\n", srcWordsWeight) - fmt.Printf("dstWordsWeight: %v\n", dstWordsWeight) - - srcWords := make([]textcomparison.WordWeight, len(srcWordsWeight)) - dstWords := make([]textcomparison.WordWeight, len(dstWordsWeight)) - - for i, ww := range srcWordsWeight { - word := textcomparison.WordWeight{Word: ww.Word, Weight: ww.Weight} - srcWords[i] = word - } - for i, ww := range dstWordsWeight { - word := textcomparison.WordWeight{Word: ww.Word, Weight: ww.Weight} - dstWords[i] = word - } - fmt.Printf("srcWords:%v\n", srcWords) - fmt.Printf("dstWords:%v\n", dstWords) - - distance, err := textcomparison.SimHashSimilar(srcWords, dstWords) - if err != nil { - // t.Errorf("failed: %v", err.Error()) - fmt.Printf("failed:%v\n", c.Errors) - } - fmt.Printf("SimHashSimilar distance:%v\n", distance) + // participle := textcomparison.NewGoJieba() + // //去除文本Html标签 + // srcStr := textcomparison.RemoveHtml("关于区块链和数字货币的关系,很多人或多或少都存在疑惑。简单来说,区块链是比特币的底层运用,而比特币只是区块链的一个小应用而已。" + + // "数字货币即虚拟货币,最早的数字货币诞生于2009年,其发明者中本聪为了应对经济危机对于实体货币经济的冲击。比特币是最早的数字货币,后来出现了以太币、火币以及莱特币等虚拟货币,这些虚拟货币是不能用来交易的。" + + // "狭义来讲,区块链是一种按照时间顺序将数据区块以顺序相连的方式组合成的一种链式数据结构, 并以密码学方式保证的不可篡改和不可伪造的分布式账本。" + + // "广义来讲,区块链技术是利用块链式数据结构来验证与存储数据、利用分布式节点共识算法来生成和更新数据、利用密码学的方式保证数据传输和访问的安全、利用由自动化脚本代码组成的智能合约来编程和操作数据的一种全新的分布式基础架构与计算方式。") + // dstStr := textcomparison.RemoveHtml("区块链技术为我们的信息防伪与数据追踪提供了革新手段。区块链中的数据区块顺序相连构成了一个不可篡改的数据链条,时间戳为所有的交易行为贴上了一套不讲课伪造的真是标签,这对于人们在现实生活中打击假冒伪劣产品大有裨益; " + + // "市场分析指出,整体而言,区块链技术目前在十大金融领域显示出应用前景,分别是资产证券化、保险、供应链金融、场外市场、资产托管、大宗商品交易、风险信息共享机制、贸易融资、银团贷款、股权交易交割。" + + // "这些金融场景有三大共性:参与节点多、验真成本高、交易流程长,而区块链的分布式记账、不可篡改、内置合约等特性可以为这些金融业务中的痛点提供解决方案。" + + // "传统的工业互联网模式是由一个中心化的机构收集和管理所有的数据信息,容易产生因设备生命周期和安全等方面的缺陷引起的数据丢失、篡改等问题。区块链技术可以在无需任何信任单个节点的同时构建整个网络的信任共识,从而很好的解决目前工业互联网技术领域的一些缺陷,让物与物之间能够实现更好的连接.") + + // srcWordsWeight := participle.C.ExtractWithWeight(srcStr, 30) + // dstWordsWeight := participle.C.ExtractWithWeight(dstStr, 30) + // fmt.Printf("srcWordsWeight: %v\n", srcWordsWeight) + // fmt.Printf("dstWordsWeight: %v\n", dstWordsWeight) + + // srcWords := make([]textcomparison.WordWeight, len(srcWordsWeight)) + // dstWords := make([]textcomparison.WordWeight, len(dstWordsWeight)) + + // for i, ww := range srcWordsWeight { + // word := textcomparison.WordWeight{Word: ww.Word, Weight: ww.Weight} + // srcWords[i] = word + // } + // for i, ww := range dstWordsWeight { + // word := textcomparison.WordWeight{Word: ww.Word, Weight: ww.Weight} + // dstWords[i] = word + // } + // fmt.Printf("srcWords:%v\n", srcWords) + // fmt.Printf("dstWords:%v\n", dstWords) + + // distance, err := textcomparison.SimHashSimilar(srcWords, dstWords) + // if err != nil { + // // t.Errorf("failed: %v", err.Error()) + // fmt.Printf("failed:%v\n", c.Errors) + // } + // fmt.Printf("SimHashSimilar distance:%v\n", distance) // t.Logf("SimHashSimilar distance: %v", distance) } @@ -3051,3 +3051,33 @@ func (s *ShiyanApi) DingXingPass(c *gin.Context) { } response.Result(0, errVal, "处理完成", c) } + +/* +* +@ 作者: 秦东 +@ 时间: 2022-09-30 16:23:30 +@ 功能: 实验拼音 +@ 参数 + + # + +@ 返回值 + + # +*/ +type pinyin struct { + TextStr string `json:"textstr"` +} + +func (s *ShiyanApi) ShiyanPinYin(c *gin.Context) { + var requestData pinyin + c.ShouldBindJSON(&requestData) + a, aErr := textcomparison.ChinaToPinYinFirstBig(requestData.TextStr) + b, bErr := textcomparison.ChinaToPinYinFirstWord(requestData.TextStr) + fmt.Printf("a:%v--------->aErr:%v----------->b:%v----------->bErr:%v\n", a, aErr, b, bErr) + errVal := commonus.MapOut() + errVal["a"] = a + errVal["b"] = b + response.Result(0, errVal, "处理完成", c) + +} diff --git a/api/v1/staff/staffpeople.go b/api/v1/staff/staffpeople.go index cce101d..95703cd 100644 --- a/api/v1/staff/staffpeople.go +++ b/api/v1/staff/staffpeople.go @@ -3,12 +3,12 @@ package staff import ( "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/systemuser" + "gin_server_admin/model/testpage" "github.com/gin-gonic/gin" ) @@ -21,7 +21,7 @@ func (s *StaffPeople) Index(c *gin.Context) { response.Result(0, outPut, "获取成功", c) } -//获得员工列表 +// 获得员工列表 func (s *StaffPeople) StaffList(c *gin.Context) { var requestData staffRequest err := c.ShouldBindJSON(&requestData) @@ -148,7 +148,7 @@ func (s *StaffPeople) StaffList(c *gin.Context) { response.Result(0, printData, "查询成功!", c) } -//通过账号密码获取用户信息 +// 通过账号密码获取用户信息 func GetUserWork(userName, userPwd string) (isTrue bool, staffInfo staffOutInfo) { isTrue = false var md5JiaMi commonus.Md5Encryption @@ -230,7 +230,7 @@ func GetUserWork(userName, userPwd string) (isTrue bool, staffInfo staffOutInfo) return } -//通过Hr系统登录确认 +// 通过Hr系统登录确认 func HrUserInfor(number, pwd string) (isTrue bool, usUpdate OutScanCodeUserInfo) { isTrue = false @@ -326,7 +326,7 @@ func HrUserInforold(number, pwd string) (isTrue bool, usUpdate OutScanCodeUserIn return } -//获取权限点位 +// 获取权限点位 func getRoleInt(roleId string) (menuStr, buttonStr string) { var roleInfo systemuser.SystemRole err := global.GVA_DB_Master.Where("`r_id` = ?", roleId).First(&roleInfo).Error @@ -338,7 +338,7 @@ func getRoleInt(roleId string) (menuStr, buttonStr string) { return } -//获取员工公司组织 +// 获取员工公司组织 func getOrgCont(id string) (oldId, orgName string) { var orgInfo hrsystem.AdministrativeOrganization err := global.GVA_DB_HrDataBase.Where("`id` = ?", id).First(&orgInfo).Error @@ -350,7 +350,7 @@ func getOrgCont(id string) (oldId, orgName string) { return } -//获得员工列表 +// 获得员工列表 func (s *StaffPeople) StaffListes(c *gin.Context) { // var requestData staffRequest // err := c.ShouldBindJSON(&requestData) diff --git a/api/v1/staff/stafftype.go b/api/v1/staff/stafftype.go index 1d28fb4..cb98867 100644 --- a/api/v1/staff/stafftype.go +++ b/api/v1/staff/stafftype.go @@ -1,9 +1,9 @@ package staff import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/testpage" ) type staffRequest struct { @@ -16,7 +16,7 @@ type staffRequest struct { UserName string `json:"username"` } -//输出员工信息 +// 输出员工信息 type staffOutInfo struct { testpage.PersonalDetails KeyStr string `json:"keystr"` @@ -27,7 +27,7 @@ type staffOutInfo struct { TemaTitle string `json:"temaTitle"` } -//组织架构员工对照表 +// 组织架构员工对照表 type groupRequest struct { GroupId int64 `json:"groupId"` } @@ -38,7 +38,7 @@ type groupUser struct { Children []groupUser `json:"groupUser"` } -//输出 +// 输出 type OutScanCodeUserInfo struct { global.GAV_USER_CONT State int `json:"state"` diff --git a/api/v1/system/enter.go b/api/v1/system/enter.go index 995522c..40aac9d 100644 --- a/api/v1/system/enter.go +++ b/api/v1/system/enter.go @@ -1,6 +1,6 @@ package system -import "github.com/flipped-aurora/gin-vue-admin/server/service" +import "gin_server_admin/service" type ApiGroup struct { SystemApiApi diff --git a/api/v1/system/sys_api.go b/api/v1/system/sys_api.go index ba7fb8a..1b0c64e 100644 --- a/api/v1/system/sys_api.go +++ b/api/v1/system/sys_api.go @@ -1,13 +1,13 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/api/v1/system/sys_authority.go b/api/v1/system/sys_authority.go index 5cb6d96..28cbfb3 100644 --- a/api/v1/system/sys_authority.go +++ b/api/v1/system/sys_authority.go @@ -1,13 +1,13 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/api/v1/system/sys_auto_code.go b/api/v1/system/sys_auto_code.go index e8b7b04..219da17 100644 --- a/api/v1/system/sys_auto_code.go +++ b/api/v1/system/sys_auto_code.go @@ -6,11 +6,11 @@ import ( "net/url" "os" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/api/v1/system/sys_captcha.go b/api/v1/system/sys_captcha.go index f07587d..5ce93ba 100644 --- a/api/v1/system/sys_captcha.go +++ b/api/v1/system/sys_captcha.go @@ -1,16 +1,16 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + systemRes "gin_server_admin/model/system/response" "github.com/gin-gonic/gin" "github.com/mojocn/base64Captcha" "go.uber.org/zap" ) // 当开启多服务器部署时,替换下面的配置,使用redis共享存储验证码 -//var store = captcha.NewDefaultRedisStore() +// var store = captcha.NewDefaultRedisStore() var store = base64Captcha.DefaultMemStore type BaseApi struct { diff --git a/api/v1/system/sys_casbin.go b/api/v1/system/sys_casbin.go index ce2f1bc..6a39298 100644 --- a/api/v1/system/sys_casbin.go +++ b/api/v1/system/sys_casbin.go @@ -1,11 +1,11 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system/request" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/system/sys_dictionary.go b/api/v1/system/sys_dictionary.go index 4b7b394..812c093 100644 --- a/api/v1/system/sys_dictionary.go +++ b/api/v1/system/sys_dictionary.go @@ -1,11 +1,11 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/system/sys_dictionary_detail.go b/api/v1/system/sys_dictionary_detail.go index 4984462..fbd9ca5 100644 --- a/api/v1/system/sys_dictionary_detail.go +++ b/api/v1/system/sys_dictionary_detail.go @@ -1,11 +1,11 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/system/sys_initdb.go b/api/v1/system/sys_initdb.go index 0d062a9..360a345 100644 --- a/api/v1/system/sys_initdb.go +++ b/api/v1/system/sys_initdb.go @@ -1,9 +1,9 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system/request" "go.uber.org/zap" "github.com/gin-gonic/gin" diff --git a/api/v1/system/sys_jwt_blacklist.go b/api/v1/system/sys_jwt_blacklist.go index a3ecb2d..96eb70d 100644 --- a/api/v1/system/sys_jwt_blacklist.go +++ b/api/v1/system/sys_jwt_blacklist.go @@ -1,9 +1,9 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/system/sys_menu.go b/api/v1/system/sys_menu.go index d013936..0397249 100644 --- a/api/v1/system/sys_menu.go +++ b/api/v1/system/sys_menu.go @@ -1,13 +1,13 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/api/v1/system/sys_operation_record.go b/api/v1/system/sys_operation_record.go index 8bf165a..b62b70d 100644 --- a/api/v1/system/sys_operation_record.go +++ b/api/v1/system/sys_operation_record.go @@ -1,12 +1,12 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/api/v1/system/sys_system.go b/api/v1/system/sys_system.go index c344bac..95c2f5c 100644 --- a/api/v1/system/sys_system.go +++ b/api/v1/system/sys_system.go @@ -1,11 +1,11 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/api/v1/system/sys_user.go b/api/v1/system/sys_user.go index 69490cc..781aba5 100644 --- a/api/v1/system/sys_user.go +++ b/api/v1/system/sys_user.go @@ -3,13 +3,13 @@ package system import ( "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - systemRes "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" + systemRes "gin_server_admin/model/system/response" + "gin_server_admin/utils" "github.com/gin-gonic/gin" "github.com/go-redis/redis/v8" diff --git a/api/v1/wechatcallback/wechatcallbackhanlde.go b/api/v1/wechatcallback/wechatcallbackhanlde.go index 739e4c3..ba0d987 100644 --- a/api/v1/wechatcallback/wechatcallbackhanlde.go +++ b/api/v1/wechatcallback/wechatcallbackhanlde.go @@ -5,7 +5,7 @@ import ( "encoding/xml" "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" + "gin_server_admin/commonus" ) func templateEventPush(eventMsg []byte) { diff --git a/api/v1/wechatcallback/wechatcallbackmain.go b/api/v1/wechatcallback/wechatcallbackmain.go index c8a06aa..4a87994 100644 --- a/api/v1/wechatcallback/wechatcallbackmain.go +++ b/api/v1/wechatcallback/wechatcallbackmain.go @@ -8,15 +8,15 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechatcallback" - "github.com/flipped-aurora/gin-vue-admin/server/wechatjiexi/wxbizmsgcrypt" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/wechatcallback" + "gin_server_admin/wechatjiexi/wxbizmsgcrypt" "github.com/gin-gonic/gin" ) -//回调首页 +// 回调首页 func (w *WeChatCallBackApi) Index(c *gin.Context) { // token := global.GVA_CONFIG.WorkWechatId.Token @@ -73,7 +73,7 @@ func (w *WeChatCallBackApi) Index(c *gin.Context) { response.Result(0, sendData, "获取成功", c) } -//API接收消息 +// API接收消息 func (w *WeChatCallBackApi) CallbackApiMessage(c *gin.Context) { MsgSignature := c.Query("msg_signature") //企业微信加密签名,msg_signature计算结合了企业填写的token、请求中的timestamp、nonce、加密的消息体。 Timestamp := c.Query("timestamp") //时间戳。与nonce结合使用,用于防止请求重放攻击。 @@ -109,7 +109,7 @@ func (w *WeChatCallBackApi) CallbackApiMessage(c *gin.Context) { } } -//启动企业微信验证程序 +// 启动企业微信验证程序 func WechatVerification() (wxcpt *wxbizmsgcrypt.WXBizMsgCrypt) { //正式数据 token := "kkUA3s2s3" @@ -126,7 +126,7 @@ func WechatVerification() (wxcpt *wxbizmsgcrypt.WXBizMsgCrypt) { return } -//验证URL +// 验证URL func (c *CallBackData) VerificationUrl() (msg string) { wecahtCpt := WechatVerification() timestampStr := strconv.FormatInt(c.Timestamp, 10) @@ -151,7 +151,7 @@ func (c *CallBackData) VerificationUrl() (msg string) { } -//解析消息结构 +// 解析消息结构 func (c *CallBackData) DecryptMessage() { wecahtCpt := WechatVerification() timestampStr := strconv.FormatInt(c.Timestamp, 10) @@ -203,7 +203,7 @@ func (c *CallBackData) DecryptMessage() { global.GVA_DB_WechatCallBack.Create(&callbackLog) } -//企业微信事件处理 +// 企业微信事件处理 func EventProcessing(event string, decryptMsg []byte) { var msgContent MsgContentMailList err := xml.Unmarshal(decryptMsg, &msgContent) @@ -236,7 +236,7 @@ func EventProcessing(event string, decryptMsg []byte) { } } -//企业微信通讯录变更事件处理 +// 企业微信通讯录变更事件处理 func WorkWechatMailList(changeType string, decryptMsg []byte) { switch changeType { case "create_party": //新增部门事件 diff --git a/api/web/enter.go b/api/web/enter.go index 462ff08..e542878 100644 --- a/api/web/enter.go +++ b/api/web/enter.go @@ -1,6 +1,6 @@ package web -import "github.com/flipped-aurora/gin-vue-admin/server/api/web/jixiaokaohe" +import "gin_server_admin/api/web/jixiaokaohe" type WebApi struct { AchApiGroup jixiaokaohe.ApiGroup diff --git a/api/web/jixiaokaohe/enter.go b/api/web/jixiaokaohe/enter.go index b56a570..d39b2d8 100644 --- a/api/web/jixiaokaohe/enter.go +++ b/api/web/jixiaokaohe/enter.go @@ -1,6 +1,6 @@ package jixiaokaohe -import "github.com/flipped-aurora/gin-vue-admin/server/commonus" +import "gin_server_admin/commonus" type ApiGroup struct{} diff --git a/api/web/jixiaokaohe/myduty.go b/api/web/jixiaokaohe/myduty.go index 9181948..12237bc 100644 --- a/api/web/jixiaokaohe/myduty.go +++ b/api/web/jixiaokaohe/myduty.go @@ -4,10 +4,10 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) @@ -16,7 +16,7 @@ func (a *ApiGroup) Index(c *gin.Context) { response.Result(0, outPut, "手机考核入口", c) } -//获取关于本人要进行的项目 +// 获取关于本人要进行的项目 func (a *ApiGroup) AboutMyTask(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { @@ -60,7 +60,7 @@ func (a *ApiGroup) AboutMyTask(c *gin.Context) { response.Result(0, outSunTargetList, "获取成功", c) } -//获取考核指标细则 +// 获取考核指标细则 func (a *ApiGroup) TaskParameterTitleList(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/web/jixiaokaohe/people.go b/api/web/jixiaokaohe/people.go index d43aa52..57a9189 100644 --- a/api/web/jixiaokaohe/people.go +++ b/api/web/jixiaokaohe/people.go @@ -3,14 +3,14 @@ package jixiaokaohe import ( "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" "github.com/gin-gonic/gin" ) -//获取个人信息 +// 获取个人信息 func (a *ApiGroup) MyContent(c *gin.Context) { isTrue, userCont := commonus.ClientIdentity() if isTrue != true { diff --git a/api/wechatapp/callback/apphandle.go b/api/wechatapp/callback/apphandle.go index 573f01e..ebf0669 100644 --- a/api/wechatapp/callback/apphandle.go +++ b/api/wechatapp/callback/apphandle.go @@ -8,22 +8,22 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechatcallback" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" - "github.com/flipped-aurora/gin-vue-admin/server/wechatjiexi/wxbizmsgcrypt" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/wechatcallback" + "gin_server_admin/utils/redishandel" + "gin_server_admin/wechatjiexi/wxbizmsgcrypt" "github.com/gin-gonic/gin" ) -//入口 +// 入口 func (a *CallBackApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "企业微信回调入口", c) } -//回调入口 +// 回调入口 func (a *CallBackApi) CallbackMessageApi(c *gin.Context) { MsgSignature := c.Query("msg_signature") //企业微信加密签名,msg_signature计算结合了企业填写的token、请求中的timestamp、nonce、加密的消息体。 Timestamp := c.Query("timestamp") //时间戳。与nonce结合使用,用于防止请求重放攻击。 @@ -59,7 +59,7 @@ func (a *CallBackApi) CallbackMessageApi(c *gin.Context) { } } -//启动企业微信验证程序 +// 启动企业微信验证程序 func WechatVerification() (wxcpt *wxbizmsgcrypt.WXBizMsgCrypt) { //正式数据 // token := "kkUA3s2s3" @@ -67,7 +67,7 @@ func WechatVerification() (wxcpt *wxbizmsgcrypt.WXBizMsgCrypt) { receiverId := global.GVA_CONFIG.WorkWechatId.CompanyId encodingAeskey := global.GVA_CONFIG.WorkWechatSchool.EncodingAESKey - // fmt.Printf("------->%v------->%v------->%v\n", token, receiverId, encodingAeskey) + fmt.Printf("------->%v------->%v------->%v\n", token, receiverId, encodingAeskey) //测试数据 // token := "QDG6eK" // receiverId := "wx5823bf96d3bd56c7" @@ -76,11 +76,16 @@ func WechatVerification() (wxcpt *wxbizmsgcrypt.WXBizMsgCrypt) { return } -//验证URL +// 验证URL func (c *CallBackData) VerificationUrl() (msg string) { wecahtCpt := WechatVerification() timestampStr := strconv.FormatInt(c.Timestamp, 10) + jsonk, _ := json.Marshal(c) + fmt.Printf("json--------->%v\n", string(jsonk)) echoStr, cryptErr := wecahtCpt.VerifyURL(c.MsgSignature, timestampStr, c.Nonce, c.Echostr) + + fmt.Printf("(2)wxcptJson---------->%v-----MsgSignature--->%v----Timestamp---->%v-----Nonce--->%v-----c.Echostr--->%v------------echoStr------->%v----cryptErr---->%v\n", wecahtCpt, c.MsgSignature, c.Timestamp, c.Nonce, c.Echostr, string(echoStr), cryptErr) + var callbackLog wechatcallback.CallbackLog // callbackLog.MsgSignature = c.MsgSignature @@ -101,7 +106,7 @@ func (c *CallBackData) VerificationUrl() (msg string) { } -//解析消息结构 +// 解析消息结构 func (c *CallBackData) DecryptMessage(cs *gin.Context) (echoMsg string) { wecahtCpt := WechatVerification() timestampStr := strconv.FormatInt(c.Timestamp, 10) @@ -186,7 +191,7 @@ func (c *CallBackData) DecryptMessage(cs *gin.Context) (echoMsg string) { return } -//企业微信事件处理 +// 企业微信事件处理 func EventProcessing(event string, decryptMsg []byte, v *CallBackData, cs *gin.Context) (msg string) { var msgContent MsgContentMailList err := xml.Unmarshal(decryptMsg, &msgContent) @@ -253,7 +258,7 @@ func EventProcessing(event string, decryptMsg []byte, v *CallBackData, cs *gin.C return } -//企业微信通讯录变更事件处理 +// 企业微信通讯录变更事件处理 func WorkWechatMailList(changeType string, decryptMsg []byte) { switch changeType { case "create_party": //新增部门事件 @@ -271,7 +276,7 @@ func WorkWechatMailList(changeType string, decryptMsg []byte) { } } -//回调写入redis +// 回调写入redis func WechatCallBackDataWruteRedis(redisKey, redisVal, class string) { redisClient := redishandel.RunRedis() redisClient.SetRedisDb(2) diff --git a/api/wechatapp/callback/eventprocessing.go b/api/wechatapp/callback/eventprocessing.go index 78f57b4..d1176a3 100644 --- a/api/wechatapp/callback/eventprocessing.go +++ b/api/wechatapp/callback/eventprocessing.go @@ -6,13 +6,13 @@ import ( "fmt" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/utils/redishandel" ) -//相关事件处理 +// 相关事件处理 func GeographicalPosition(eventMsg []byte) { //进入应用上报地址位置 var msgContent GeographicalPositionType err := xml.Unmarshal(eventMsg, &msgContent) @@ -66,7 +66,7 @@ func GeographicalPosition(eventMsg []byte) { //进入应用上报地址位置 // fmt.Printf("button======>%v======>%v======>%v\n", msgContent, long, latg) } -//自建应用审批处理 +// 自建应用审批处理 func OpenApprovalChange(eventMsg []byte) { var msgContent OpenApprovalChangeType err := xml.Unmarshal(eventMsg, &msgContent) diff --git a/api/wechatapp/callback/rationcallback.go b/api/wechatapp/callback/rationcallback.go index 752bf52..768bb91 100644 --- a/api/wechatapp/callback/rationcallback.go +++ b/api/wechatapp/callback/rationcallback.go @@ -6,10 +6,10 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) func (t *TemplateCardPush) ButtonTemplateCallBackHandleRation(orderId, clickEnter string) { @@ -177,7 +177,7 @@ func (t *TemplateCardPush) ButtonTemplateCallBackHandleRation(orderId, clickEnte } } -//编辑流程步进器 +// 编辑流程步进器 func EiteDutiesInfoes(saveId int64, saveData map[string]interface{}) (isTrue bool, infoErr error) { isTrue = false infoErr = global.GVA_DB_Performanceappraisal.Model(&assessmentmodel.FlowLog{}).Where("`fl_key` = ?", saveId).Updates(saveData).Error diff --git a/api/wechatapp/callback/sendmsg.go b/api/wechatapp/callback/sendmsg.go index 47a28a7..0914731 100644 --- a/api/wechatapp/callback/sendmsg.go +++ b/api/wechatapp/callback/sendmsg.go @@ -4,10 +4,10 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) //发送流程文本信息 diff --git a/api/wechatapp/callback/updatehandle.go b/api/wechatapp/callback/updatehandle.go index 0900d18..a74727e 100644 --- a/api/wechatapp/callback/updatehandle.go +++ b/api/wechatapp/callback/updatehandle.go @@ -8,15 +8,15 @@ import ( "strings" "time" - // evals "github.com/flipped-aurora/gin-vue-admin/server/api/index/evaluation" - evals "github.com/flipped-aurora/gin-vue-admin/server/api/index/evaluation" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + // evals "gin_server_admin/api/index/evaluation" + evals "gin_server_admin/api/index/evaluation" + "gin_server_admin/api/wechatapp/sendmessage" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" ) -//更新数据 +// 更新数据 func templateEventPush(eventMsg []byte) { var msgContent TemplateCardPush err := xml.Unmarshal(eventMsg, &msgContent) @@ -59,7 +59,7 @@ func templateEventPush(eventMsg []byte) { // fmt.Printf("更新销售发送信息返回:%v-----------%v----------->%v\n", string(callbakcMsg), isTrueCall, callBackCont) } -//发送错误信息 +// 发送错误信息 func sendErrMsg(userKey, orderId, title, cont, DepartmentName, Name, cardJumpUrl, jumpUrl string) { desc := "" reason := commonus.TimeStampToDate(time.Now().Unix(), 14) @@ -987,7 +987,7 @@ func (t *TemplateCardPush) ButtonTemplateCallBackHandleBackups(orderId, clickEnt } } -//按钮模板回调处理 +// 按钮模板回调处理 func (t *TemplateCardPush) ButtonTemplateCallBackHandle(scoreFlowKey, clickEnter string) { buttonClickNAme := "已批准" buttonClickNAmeOther := "其他人已批准" @@ -1676,7 +1676,7 @@ func (t *TemplateCardPush) ButtonTemplateCallBackHandle(scoreFlowKey, clickEnter // } } -//其他按钮处理 +// 其他按钮处理 func (t *TemplateCardPush) OtherClickButton(userAry []string, buttonClickNAmeOther string) { userInfoErr, userInfo := commonus.GetUesrContForWechatID(t.FromUsername) fmt.Printf("OtherClick------------->%v------------>%v\n", userAry, userInfo) @@ -1703,7 +1703,7 @@ func (t *TemplateCardPush) OtherClickButton(userAry []string, buttonClickNAmeOth } } -//更新按钮 +// 更新按钮 func (t *TemplateCardPush) UpdateButton(userOpenId, buttonName string) { var updateButtonNotClickable commonus.UpdateButtonNotClickable updateButtonNotClickable.Userids = append(updateButtonNotClickable.Userids, userOpenId) @@ -1727,7 +1727,7 @@ func (t *TemplateCardPush) UpdateButtonIng(userOpenId []string, buttonName strin fmt.Printf("10、更新发送信息返回:%v-----------%v----------->%v------》%v\n", string(callbakcMsg), isTrueCall, callBackCont, updateButtonNotClickable) } -//获取操作人 +// 获取操作人 func GetCaoZuoRen(stepVal int, s assessmentmodel.ScoreFlow) (sendUserList string, stepDepart int64) { //1:内勤;2:部门负责人:3:整改;4:整改后部门负责;5:归档起草人 diff --git a/api/wechatapp/enter.go b/api/wechatapp/enter.go index 070bfce..bded66e 100644 --- a/api/wechatapp/enter.go +++ b/api/wechatapp/enter.go @@ -1,11 +1,11 @@ package wechatapp import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/callback" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sendmessage" + "gin_server_admin/api/wechatapp/callback" + "gin_server_admin/api/wechatapp/sendmessage" ) -//企业微信应用 +// 企业微信应用 type ApiGroup struct { WorkWeChatCallBackApi callback.ApiGroup WorkWeChatSendMsgApi sendmessage.ApiGroup diff --git a/api/wechatapp/sendmessage/apphandle.go b/api/wechatapp/sendmessage/apphandle.go index a2dbc8e..ccbdfb2 100644 --- a/api/wechatapp/sendmessage/apphandle.go +++ b/api/wechatapp/sendmessage/apphandle.go @@ -4,20 +4,20 @@ import ( "encoding/json" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sharemethod" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/api/wechatapp/sharemethod" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//向企业微信发送消息入口 +// 向企业微信发送消息入口 func (s *SendMessageApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "企业微信回调入口", c) } -//发送文本信息 +// 发送文本信息 func (s *SendText) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -29,7 +29,7 @@ func (s *SendText) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//文本卡片消息 +// 文本卡片消息 func (s *TextcardStruct) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -41,7 +41,7 @@ func (s *TextcardStruct) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//发送markdown文本信息 +// 发送markdown文本信息 func (s *SendMarkDown) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -53,7 +53,7 @@ func (s *SendMarkDown) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//发送图文信息 +// 发送图文信息 func (s *SendImgCont) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -65,7 +65,7 @@ func (s *SendImgCont) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//图文消息(mpnews) +// 图文消息(mpnews) func (s *NewsImages) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -94,7 +94,7 @@ func (s *TextNoticeTemplate) SendMessage(appName string) ([]byte, bool, string) return addDePartMent, true, msg } -//文本通知型中配 +// 文本通知型中配 func (s *TextNoticeTemplateMedium) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -145,7 +145,7 @@ func (s *TextNoticeTemplateMedium) Inset(userList, msgType, CardType string, tas } -//文本通知型简化 +// 文本通知型简化 func (s *TextNoticeTemplateSimplify) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -157,7 +157,7 @@ func (s *TextNoticeTemplateSimplify) SendMessage(appName string) ([]byte, bool, return addDePartMent, true, msg } -//图文展示型 +// 图文展示型 func (s *ImgTextTemplate) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -169,7 +169,7 @@ func (s *ImgTextTemplate) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//图文展示型(简化) +// 图文展示型(简化) func (s *ImgTextTemplateSimplify) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -181,7 +181,7 @@ func (s *ImgTextTemplateSimplify) SendMessage(appName string) ([]byte, bool, str return addDePartMent, true, msg } -//按钮交互型 +// 按钮交互型 func (s *ButtonTemplate) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -193,7 +193,7 @@ func (s *ButtonTemplate) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//按钮交互型中配 +// 按钮交互型中配 func (s *ButtonNoticeTemplateMedium) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -205,7 +205,7 @@ func (s *ButtonNoticeTemplateMedium) SendMessage(appName string) ([]byte, bool, return addDePartMent, true, msg } -//按钮交互型中配 +// 按钮交互型中配 func (s *ButtonNoticeTemplateMedium) Inset(userList, msgType, CardType string, taskId int64) { s.Touser = userList if CardType != "" { @@ -239,7 +239,7 @@ func (s *ButtonNoticeTemplateMedium) Inset(userList, msgType, CardType string, t } -//投票选择型 +// 投票选择型 func (s *VoteTemplate) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -251,7 +251,7 @@ func (s *VoteTemplate) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//查询自建应用审批单当前状态 +// 查询自建应用审批单当前状态 func (s *OpenApprovalState) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.QueryStateOpenApprovalAata(appName) if IsTrue == false { @@ -263,7 +263,7 @@ func (s *OpenApprovalState) SendMessage(appName string) ([]byte, bool, string) { return addDePartMent, true, msg } -//图文展示型 +// 图文展示型 func (s *TextNoticeTemplateSimplifyes) SendMessage(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetSendMsgTokenUrl(appName) if IsTrue == false { @@ -275,7 +275,7 @@ func (s *TextNoticeTemplateSimplifyes) SendMessage(appName string) ([]byte, bool return addDePartMent, true, msg } -//发送文本信息初始化 +// 发送文本信息初始化 func (s *TextNoticeTemplateMedium) InsetCont(userList, msgType, CardType, taskId string) { s.Touser = userList if CardType != "" { @@ -309,7 +309,7 @@ func (s *TextNoticeTemplateMedium) InsetCont(userList, msgType, CardType, taskId } -//发送文本信息初始化新版本 +// 发送文本信息初始化新版本 func (s *TextNoticeTemplateMedium) InsetContNew(userList, msgType, CardType, taskId, sourceDesc string) { s.Touser = userList if CardType != "" { diff --git a/api/wechatapp/sendmessage/examineapprove.go b/api/wechatapp/sendmessage/examineapprove.go index 87b2e34..50f8b01 100644 --- a/api/wechatapp/sendmessage/examineapprove.go +++ b/api/wechatapp/sendmessage/examineapprove.go @@ -4,11 +4,11 @@ import ( "encoding/json" "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp/sharemethod" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" + "gin_server_admin/api/wechatapp/sharemethod" + "gin_server_admin/commonus" ) -//审批相关操作 +// 审批相关操作 func (s *TemplatedEtailType) GetTemplatedeTail(appName string) ([]byte, bool, string) { sendUrl, IsTrue, msg := sharemethod.GetExamineApprove(appName) if IsTrue == false { @@ -22,7 +22,7 @@ func (s *TemplatedEtailType) GetTemplatedeTail(appName string) ([]byte, bool, st //获取企业的jsapi_ticket -//计算JS-SDK使用权限签名算法 +// 计算JS-SDK使用权限签名算法 func JsSdkSignAlgorithm(appName string, state int) (sendUrlstr string, isTrue bool, msg string) { // fmt.Printf("1======>%v\n", state) sendUrlstr, isTrue, msg = sharemethod.GetExamineApproveSign(appName, state) diff --git a/api/wechatapp/sendmessage/sendmsgHandle.go b/api/wechatapp/sendmessage/sendmsgHandle.go index 525da55..824c251 100644 --- a/api/wechatapp/sendmessage/sendmsgHandle.go +++ b/api/wechatapp/sendmessage/sendmsgHandle.go @@ -4,7 +4,7 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" + "gin_server_admin/commonus" ) /* @@ -189,7 +189,7 @@ func SendButtonPublic(sendUserList, Title, Desc, subtitle, reason string, depart return } -//定量 +// 定量 func SendButtonPublicRation(sendUserList, Title, Desc, subtitle, reason string, departmentId, userKey, keyNumber, orderId int64, buttonMap []ButtonListtype) (callbakcMsg []byte, isTrueCall bool, callBackCont string, send ButtonNoticeTemplateMedium) { var sendTextMsg ButtonNoticeTemplateMedium sendTextMsg.Inset(sendUserList, "template_card", "button_interaction", keyNumber) diff --git a/api/wechatapp/sharemethod/handle.go b/api/wechatapp/sharemethod/handle.go index b32e6fe..d0bfcf6 100644 --- a/api/wechatapp/sharemethod/handle.go +++ b/api/wechatapp/sharemethod/handle.go @@ -4,14 +4,14 @@ import ( "encoding/json" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/utils/redishandel" ) //获取企业微信token -//获取企业微信token +// 获取企业微信token func GetWechatToken(types string) (tokenInfo string, redisClient *redishandel.RedisStoreType, err error) { redisClient = redishandel.RunRedis() redisClient.SetRedisDb(1) @@ -53,7 +53,7 @@ func GetWechatToken(types string) (tokenInfo string, redisClient *redishandel.Re return } -//获取发送应用消息地址及相关地址参数 +// 获取发送应用消息地址及相关地址参数 func GetSendMsgTokenUrl(appName string) (sendUrlstr string, isTrue bool, msg string) { isTrue = false ton, _, err := GetWechatToken(appName) @@ -67,7 +67,7 @@ func GetSendMsgTokenUrl(appName string) (sendUrlstr string, isTrue bool, msg str return } -//获取更新模板消息地址及相关地址参数 +// 获取更新模板消息地址及相关地址参数 func GetUpdateMsgTokenUrl(appName string) (sendUrlstr string, isTrue bool, msg string) { isTrue = false ton, _, err := GetWechatToken(appName) @@ -81,7 +81,7 @@ func GetUpdateMsgTokenUrl(appName string) (sendUrlstr string, isTrue bool, msg s return } -//获取审批模板详情 +// 获取审批模板详情 func GetExamineApprove(appName string) (sendUrlstr string, isTrue bool, msg string) { isTrue = false ton, _, err := GetWechatToken(appName) @@ -95,8 +95,8 @@ func GetExamineApprove(appName string) (sendUrlstr string, isTrue bool, msg stri return } -//获取企业的jsapi_ticket 或 获取应用的jsapi_ticket -//获取审批模板详情 +// 获取企业的jsapi_ticket 或 获取应用的jsapi_ticket +// 获取审批模板详情 func GetExamineApproveSign(appName string, state int) (sendUrlstr string, isTrue bool, msg string) { isTrue = false ton, _, err := GetWechatToken(appName) @@ -161,7 +161,7 @@ func GetJsapiTicket(types, callUrl string, state int) (tokenInfo string, err err return } -//查询自建应用审批单当前状态 +// 查询自建应用审批单当前状态 func QueryStateOpenApprovalAata(appName string) (sendUrlstr string, isTrue bool, msg string) { isTrue = false ton, _, err := GetWechatToken(appName) diff --git a/api/workwechatcallback/callbackes/workwechatcallback.go b/api/workwechatcallback/callbackes/workwechatcallback.go index b5fd265..99fa628 100644 --- a/api/workwechatcallback/callbackes/workwechatcallback.go +++ b/api/workwechatcallback/callbackes/workwechatcallback.go @@ -1,12 +1,12 @@ package callbackes import ( - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/commonus" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) -//验证URL +// 验证URL func (w *WorkWeChatCallBackApi) Index(c *gin.Context) { outPut := commonus.MapOut() response.Result(0, outPut, "企业微信回调入口1231234213", c) diff --git a/api/workwechatcallback/enter.go b/api/workwechatcallback/enter.go index 30354a2..ad88df1 100644 --- a/api/workwechatcallback/enter.go +++ b/api/workwechatcallback/enter.go @@ -1,6 +1,6 @@ package workwechatcallback -import "github.com/flipped-aurora/gin-vue-admin/server/api/workwechatcallback/callbackes" +import "gin_server_admin/api/workwechatcallback/callbackes" //企业微信回调 type ApiGroup struct { diff --git a/api/xml_callback/sample.go b/api/xml_callback/sample.go index 50c0171..b718e91 100644 --- a/api/xml_callback/sample.go +++ b/api/xml_callback/sample.go @@ -4,7 +4,7 @@ import ( "encoding/xml" "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/wechatjiexi/wxbizmsgcrypt" + "gin_server_admin/wechatjiexi/wxbizmsgcrypt" ) type MsgContent struct { diff --git a/commonus/floataccuracy.go b/commonus/floataccuracy.go index b4161fe..e0c3115 100644 --- a/commonus/floataccuracy.go +++ b/commonus/floataccuracy.go @@ -6,12 +6,12 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" "github.com/shopspring/decimal" ) -//float精度运算 +// float精度运算 func FloatAccuracyOperation(floatVal float64) (res float64) { num, _ := strconv.ParseFloat(fmt.Sprintf("%.8f", floatVal), 64) fmt.Println(num) @@ -23,7 +23,7 @@ func FloatAccuracyOperation(floatVal float64) (res float64) { return } -//获取编号 +// 获取编号 func GetFileNumber() (num int64) { randVal := rand.Intn(1000) timeVal := time.Now().Unix() diff --git a/commonus/md5Sub.go b/commonus/md5Sub.go index ad5fc79..7afdfa0 100644 --- a/commonus/md5Sub.go +++ b/commonus/md5Sub.go @@ -10,8 +10,8 @@ import ( "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus/snowflake" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/commonus/snowflake" + "gin_server_admin/global" ) // import ( @@ -32,7 +32,7 @@ import ( // return md5str1 // } -//获取编号(副本) +// 获取编号(副本) func GetFileNumberEs() (num int64) { node, err := snowflake.NewWorker(2) @@ -89,13 +89,13 @@ func (m *Md5Encryption) Md5EncryptionAlgorithm() (md5Val string) { return } -//初始化程序 +// 初始化程序 func (m *Md5Encryption) Md5EncryptionInit(code string) { m.AppKey = global.GVA_CONFIG.MyConfig.AppKey m.Code = code } -//sha1算法 +// sha1算法 func Sha1Encryption(str string) string { sha1 := sha1.New() sha1.Write([]byte(str)) diff --git a/commonus/publichaneld.go b/commonus/publichaneld.go index 75ce23b..4ab88a3 100644 --- a/commonus/publichaneld.go +++ b/commonus/publichaneld.go @@ -13,14 +13,14 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/assessmentmodel" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/model/location" - "github.com/flipped-aurora/gin-vue-admin/server/model/systemuser" - "github.com/flipped-aurora/gin-vue-admin/server/model/testpage" - "github.com/flipped-aurora/gin-vue-admin/server/model/wechat" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/global" + "gin_server_admin/model/assessmentmodel" + "gin_server_admin/model/hrsystem" + "gin_server_admin/model/location" + "gin_server_admin/model/systemuser" + "gin_server_admin/model/testpage" + "gin_server_admin/model/wechat" + "gin_server_admin/utils/redishandel" "github.com/mitchellh/mapstructure" "github.com/mozillazg/go-pinyin" "gorm.io/gorm" diff --git a/commonus/publicstruct.go b/commonus/publicstruct.go index e42430a..c04b957 100644 --- a/commonus/publicstruct.go +++ b/commonus/publicstruct.go @@ -1,6 +1,6 @@ package commonus -import "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" +import "gin_server_admin/model/hrsystem" //公共变量 type SetId struct { diff --git a/commonus/wechatapp.go b/commonus/wechatapp.go index 5cc5a1b..f9bd13b 100644 --- a/commonus/wechatapp.go +++ b/commonus/wechatapp.go @@ -6,8 +6,8 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/global" + "gin_server_admin/utils/redishandel" "github.com/mitchellh/mapstructure" ) diff --git a/config.docker.yaml b/config.docker.yaml index 4ae96ec..37e4143 100644 --- a/config.docker.yaml +++ b/config.docker.yaml @@ -1,4 +1,4 @@ -# github.com/flipped-aurora/gin-vue-admin/server Global Configuration +# gin_server_admin Global Configuration # jwt configuration jwt: @@ -10,7 +10,7 @@ jwt: zap: level: 'info' format: 'console' - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: 'log' link-name: 'latest_log' show-line: true @@ -110,7 +110,7 @@ tencent-cos: secret-id: 'xxxxxxxx' secret-key: 'xxxxxxxx' base-url: 'https://gin.vue.admin' - path-prefix: 'github.com/flipped-aurora/gin-vue-admin/server' + path-prefix: 'gin_server_admin' # excel configuration excel: diff --git a/config.yaml b/config.yaml index 6f26991..bfa4105 100644 --- a/config.yaml +++ b/config.yaml @@ -1,4 +1,4 @@ -# github.com/flipped-aurora/gin-vue-admin/server Global Configuration +# gin_server_admin Global Configuration # jwt configuration jwt: @@ -10,7 +10,7 @@ jwt: zap: level: 'info' format: 'console' - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: 'log' show-line: true encode-level: 'LowercaseColorLevelEncoder' @@ -72,7 +72,7 @@ captcha: img-height: 80 # mysql connect configuration -# 未初始化之前请勿手动修改数据库信息!!!如果一定要手动初始化请看(https://www.github.com/flipped-aurora/gin-vue-admin/server.com/docs/first) +# 未初始化之前请勿手动修改数据库信息!!!如果一定要手动初始化请看(https://www.gin_server_admin.com/docs/first) mysql: path: '127.0.0.1:3306' config: 'charset=utf8mb4&parseTime=True&loc=Local' @@ -133,7 +133,7 @@ tencent-cos: secret-id: 'xxxxxxxx' secret-key: 'xxxxxxxx' base-url: 'https://gin.vue.admin' - path-prefix: 'github.com/flipped-aurora/gin-vue-admin/server' + path-prefix: 'gin_server_admin' # excel configuration excel: diff --git a/config_server.yaml b/config_server.yaml index 0d74ee9..f060cb4 100644 --- a/config_server.yaml +++ b/config_server.yaml @@ -82,7 +82,7 @@ tencent-cos: secret-id: xxxxxxxx secret-key: xxxxxxxx base-url: https://gin.vue.admin - path-prefix: github.com/flipped-aurora/gin-vue-admin/server + path-prefix: gin_server_admin timer: start: true spec: '@daily' @@ -96,7 +96,7 @@ timer: zap: level: info format: console - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: log showLine: true encode-level: LowercaseColorLevelEncoder diff --git a/core/server.go b/core/server.go index c2ff9bd..ed57baf 100644 --- a/core/server.go +++ b/core/server.go @@ -4,9 +4,9 @@ import ( "fmt" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/initialize" - "github.com/flipped-aurora/gin-vue-admin/server/service/system" + "gin_server_admin/global" + "gin_server_admin/initialize" + "gin_server_admin/service/system" "go.uber.org/zap" ) diff --git a/core/viper.go b/core/viper.go index bf0a11a..a151b0f 100644 --- a/core/viper.go +++ b/core/viper.go @@ -9,9 +9,9 @@ import ( "github.com/songzhibin97/gkit/cache/local_cache" - "github.com/flipped-aurora/gin-vue-admin/server/global" - _ "github.com/flipped-aurora/gin-vue-admin/server/packfile" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + _ "gin_server_admin/packfile" + "gin_server_admin/utils" "github.com/fsnotify/fsnotify" "github.com/spf13/viper" diff --git a/core/zap.go b/core/zap.go index 1abec96..4fee2be 100644 --- a/core/zap.go +++ b/core/zap.go @@ -5,8 +5,8 @@ import ( "os" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/utils" "go.uber.org/zap" "go.uber.org/zap/zapcore" ) diff --git a/global/global.go b/global/global.go index 3a4ab54..e1c341b 100644 --- a/global/global.go +++ b/global/global.go @@ -1,14 +1,14 @@ package global import ( - "github.com/flipped-aurora/gin-vue-admin/server/utils/timer" + "gin_server_admin/utils/timer" "github.com/songzhibin97/gkit/cache/local_cache" "golang.org/x/sync/singleflight" "go.uber.org/zap" - "github.com/flipped-aurora/gin-vue-admin/server/config" + "gin_server_admin/config" "github.com/go-redis/redis/v8" "github.com/spf13/viper" diff --git a/go.mod b/go.mod index 2622c57..d1524cd 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/flipped-aurora/gin-vue-admin/server +module gin_server_admin go 1.18 @@ -8,7 +8,6 @@ require ( github.com/casbin/casbin/v2 v2.11.0 github.com/casbin/gorm-adapter/v3 v3.0.2 github.com/dgrijalva/jwt-go v3.2.0+incompatible - github.com/flipped-aurora/gva-plugins v0.0.0-20210828060501-fc8b729b9a4a github.com/flipped-aurora/ws v1.0.2 github.com/fsnotify/fsnotify v1.4.9 github.com/fvbock/endless v0.0.0-20170109170031-447134032cb6 @@ -35,7 +34,6 @@ require ( github.com/unrolled/render v1.4.0 github.com/unrolled/secure v1.0.7 github.com/xuri/excelize/v2 v2.4.1 - github.com/yanyiwu/gojieba v1.1.2 go.uber.org/zap v1.16.0 golang.org/x/sync v0.0.0-20210220032951-036812b2e83c gorm.io/driver/mysql v1.3.3 @@ -43,6 +41,17 @@ require ( nhooyr.io/websocket v1.8.6 ) +require ( + github.com/Chain-Zhang/pinyin v0.1.3 + github.com/flipped-aurora/gva-plugins v0.0.0-20220713105221-be91568fccd7 +) + +require ( + github.com/flipped-aurora/gin-vue-admin/server v0.0.0-20210823151324-f5410430faf0 // indirect + github.com/lestrrat-go/file-rotatelogs v2.3.0+incompatible // indirect + github.com/lestrrat-go/strftime v1.0.3 // indirect +) + require ( github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible // indirect github.com/KyleBanks/depth v1.2.1 // indirect @@ -90,6 +99,7 @@ require ( github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect github.com/mozillazg/go-httpheader v0.2.1 // indirect github.com/pelletier/go-toml v1.6.0 // indirect + github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/richardlehane/mscfb v1.0.3 // indirect github.com/richardlehane/msoleps v1.0.1 // indirect diff --git a/go.sum b/go.sum index 2948552..549c3ab 100644 --- a/go.sum +++ b/go.sum @@ -17,6 +17,8 @@ github.com/Azure/azure-sdk-for-go/sdk/internal v0.7.0/go.mod h1:yqy467j36fJxcRV2 github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= +github.com/Chain-Zhang/pinyin v0.1.3 h1:RzErNyNwVa8z2sOLCuXSOtVdY/AsARb8mBzI2p2qtnE= +github.com/Chain-Zhang/pinyin v0.1.3/go.mod h1:5iHpt9p4znrnaP59/hfPMnAojajkDxQaP9io+tRMPho= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible h1:1G1pk05UrOh0NlF1oeaaix1x8XzrfjIDK47TY0Zehcw= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/KyleBanks/depth v1.2.1 h1:5h8fQADFrWtarTdtDudMmGsC7GPbOAu6RVB3ffsVFHc= @@ -89,11 +91,13 @@ github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymF github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/fastly/go-utils v0.0.0-20180712184237-d95a45783239 h1:Ghm4eQYC0nEPnSJdVkTrXpu9KtoVCSo1hg7mtI7G9KU= github.com/fastly/go-utils v0.0.0-20180712184237-d95a45783239/go.mod h1:Gdwt2ce0yfBxPvZrHkprdPPTTS3N5rwmLE8T22KBXlw= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= +github.com/flipped-aurora/gin-vue-admin/server v0.0.0-20210823151324-f5410430faf0 h1:T8SPIiUDG4MCt7V/Ha3RvxXHIDieAdT81BC+0+SrLJc= github.com/flipped-aurora/gin-vue-admin/server v0.0.0-20210823151324-f5410430faf0/go.mod h1:ksHCxOjTTQDk1Y1MrptfG6e9+s3rDJzQXkIZBHl8sws= -github.com/flipped-aurora/gva-plugins v0.0.0-20210828060501-fc8b729b9a4a h1:GEU1KU8lvWWwvHNTXaoVxonsp8t120oFQnlpAtGqKpM= -github.com/flipped-aurora/gva-plugins v0.0.0-20210828060501-fc8b729b9a4a/go.mod h1:/DpDUj/vphN4x3UaTDhTvT6aZaCasfKOGbMgPabwGv0= +github.com/flipped-aurora/gva-plugins v0.0.0-20220713105221-be91568fccd7 h1:hCCGLmcYN5CNDk3fCZb9zA6V0FaCoSMUQW4i31khgxU= +github.com/flipped-aurora/gva-plugins v0.0.0-20220713105221-be91568fccd7/go.mod h1:/DpDUj/vphN4x3UaTDhTvT6aZaCasfKOGbMgPabwGv0= github.com/flipped-aurora/ws v1.0.2 h1:oEUz7sgrbPENvgli7Q4QpC0NIEbJucgR4yjcDMg/AjY= github.com/flipped-aurora/ws v1.0.2/go.mod h1:RdyM2Fnvxx7f7A6WSmU1aAhDrQIAVW7LS/0LsAUE5mE= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= @@ -311,6 +315,7 @@ github.com/jackc/puddle v1.1.0/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dv github.com/jackc/puddle v1.1.1/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v1.1.3/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v1.2.1/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= +github.com/jehiah/go-strftime v0.0.0-20171201141054-1d33003b3869 h1:IPJ3dvxmJ4uczJe5YQdrYB16oTJlGSC/OyZDqUk9xX4= github.com/jehiah/go-strftime v0.0.0-20171201141054-1d33003b3869/go.mod h1:cJ6Cj7dQo+O6GJNiMx+Pa94qKj+TG8ONdKHgMNIyyag= github.com/jinzhu/inflection v1.0.0 h1:K317FqzuhWc8YvSVlFMCCUb36O/S9MCKRDI7QkRKD/E= github.com/jinzhu/inflection v1.0.0/go.mod h1:h+uFLlag+Qp1Va5pdKtLDYj+kHp5pxUVkryuEj+Srlc= @@ -318,6 +323,7 @@ github.com/jinzhu/now v1.1.1/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/ github.com/jinzhu/now v1.1.4/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= github.com/jinzhu/now v1.1.5 h1:/o9tlHleP7gOFmsnYNz3RGnqzefHA47wQpKrrdTIwXQ= github.com/jinzhu/now v1.1.5/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= +github.com/jonboulle/clockwork v0.1.0 h1:VKV+ZcuP6l3yW9doeqz6ziZGgcynBVQO+obU0+0hcPo= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/jordan-wright/email v0.0.0-20200824153738-3f5bafa1cd84 h1:pS0A6cr4aHYZnYwC7Uw+rwgb39+nzkm2QhwZ+S6Gn5I= github.com/jordan-wright/email v0.0.0-20200824153738-3f5bafa1cd84/go.mod h1:1c7szIrayyPPB/987hsnvNzLushdWf4o/79s3P08L8A= @@ -348,8 +354,11 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/leodido/go-urn v1.2.0 h1:hpXL4XnriNwQ/ABnpepYM/1vCLWNDfUNts8dX3xTG6Y= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= +github.com/lestrrat-go/envload v0.0.0-20180220234015-a3eb8ddeffcc h1:RKf14vYWi2ttpEmkA4aQ3j4u9dStX2t4M8UM6qqNsG8= github.com/lestrrat-go/envload v0.0.0-20180220234015-a3eb8ddeffcc/go.mod h1:kopuH9ugFRkIXf3YoqHKyrJ9YfUFsckUU9S7B+XP+is= +github.com/lestrrat-go/file-rotatelogs v2.3.0+incompatible h1:4mNlp+/SvALIPFpbXV3kxNJJno9iKFWGxSDE13Kl66Q= github.com/lestrrat-go/file-rotatelogs v2.3.0+incompatible/go.mod h1:ZQnN8lSECaebrkQytbHj4xNgtg8CR7RYXnPok8e0EHA= +github.com/lestrrat-go/strftime v1.0.3 h1:qqOPU7y+TM8Y803I8fG9c/DyKG3xH/xkng6keC1015Q= github.com/lestrrat-go/strftime v1.0.3/go.mod h1:E1nN3pCbtMSu1yjSVeyuRFVm/U0xoR76fd03sz+Qz4g= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= @@ -511,6 +520,7 @@ github.com/swaggo/gin-swagger v1.3.0/go.mod h1:oy1BRA6WvgtCp848lhxce7BnWH4C8Bxa0 github.com/swaggo/swag v1.5.1/go.mod h1:1Bl9F/ZBpVWh22nY0zmYyASPO1lI/zIwRDrpZU+tv8Y= github.com/swaggo/swag v1.7.0 h1:5bCA/MTLQoIqDXXyHfOpMeDvL9j68OY/udlK4pQoo4E= github.com/swaggo/swag v1.7.0/go.mod h1:BdPIL73gvS9NBsdi7M1JOxLvlbfvNRaBP8m6WT6Aajo= +github.com/tebeka/strftime v0.1.3 h1:5HQXOqWKYRFfNyBMNVc9z5+QzuBtIXy03psIhtdJYto= github.com/tebeka/strftime v0.1.3/go.mod h1:7wJm3dZlpr4l/oVK0t1HYIc4rMzQ2XJlOMIUJUJH6XQ= github.com/tencentyun/cos-go-sdk-v5 v0.7.19 h1:janAfTO4MglOrUFuKGTQJBuMc66+F7TgtEIt1wPsJ+k= github.com/tencentyun/cos-go-sdk-v5 v0.7.19/go.mod h1:wQBO5HdAkLjj2q6XQiIfDSP8DXDNrppDRw2Kp/1BODA= @@ -537,8 +547,6 @@ github.com/xuri/efp v0.0.0-20210322160811-ab561f5b45e3 h1:EpI0bqf/eX9SdZDwlMmahK github.com/xuri/efp v0.0.0-20210322160811-ab561f5b45e3/go.mod h1:ybY/Jr0T0GTCnYjKqmdwxyxn2BQf2RcQIIvex5QldPI= github.com/xuri/excelize/v2 v2.4.1 h1:veeeFLAJwsNEBPBlDepzPIYS1eLyBVcXNZUW79exZ1E= github.com/xuri/excelize/v2 v2.4.1/go.mod h1:rSu0C3papjzxQA3sdK8cU544TebhrPUoTOaGPIh0Q1A= -github.com/yanyiwu/gojieba v1.1.2 h1:BMwKCwg3G+Nw/Ctqzm/gNgN/6Ljf0Y4f7ddKlzTA+TM= -github.com/yanyiwu/gojieba v1.1.2/go.mod h1:54wkP7sMJ6bklf7yPl6F+JG71dzVUU1WigZbR47nGdY= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= diff --git a/initialize/gorm.go b/initialize/gorm.go index 33dcccb..d0bbd21 100644 --- a/initialize/gorm.go +++ b/initialize/gorm.go @@ -3,11 +3,11 @@ package initialize import ( "os" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/initialize/internal" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/initialize/internal" + "gin_server_admin/model/autocode" + "gin_server_admin/model/example" + "gin_server_admin/model/system" "go.uber.org/zap" "gorm.io/driver/mysql" @@ -51,9 +51,9 @@ func MysqlTables(db *gorm.DB) { example.ExaCustomer{}, system.SysOperationRecord{}, system.SysAutoCodeHistory{}, - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. autocode.AutoCodeExample{}, - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. ) if err != nil { global.GVA_LOG.Error("register table failed", zap.Any("err", err)) diff --git a/initialize/internal/logger.go b/initialize/internal/logger.go index 0841a19..5cc80c9 100644 --- a/initialize/internal/logger.go +++ b/initialize/internal/logger.go @@ -8,7 +8,7 @@ import ( "os" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "gorm.io/gorm/logger" "gorm.io/gorm/utils" ) diff --git a/initialize/plugin.go b/initialize/plugin.go index 69b8a1a..68923ce 100644 --- a/initialize/plugin.go +++ b/initialize/plugin.go @@ -1,11 +1,14 @@ package initialize import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" + email "github.com/flipped-aurora/gva-plugins/email" // 在线仓库模式go - //"github.com/flipped-aurora/gin-vue-admin/server/plugin/email" // 本地插件仓库地址模式 - "github.com/flipped-aurora/gin-vue-admin/server/plugin/example_plugin" - "github.com/flipped-aurora/gin-vue-admin/server/utils/plugin" + + //"gin_server_admin/plugin/email" // 本地插件仓库地址模式 + "gin_server_admin/plugin/example_plugin" + "gin_server_admin/utils/plugin" + "github.com/gin-gonic/gin" ) diff --git a/initialize/redis.go b/initialize/redis.go index bf92294..f3ac298 100644 --- a/initialize/redis.go +++ b/initialize/redis.go @@ -3,7 +3,7 @@ package initialize import ( "context" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/go-redis/redis/v8" "go.uber.org/zap" diff --git a/initialize/router.go b/initialize/router.go index c7cf141..8c0408f 100644 --- a/initialize/router.go +++ b/initialize/router.go @@ -3,10 +3,10 @@ package initialize import ( "net/http" - _ "github.com/flipped-aurora/gin-vue-admin/server/docs" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" - "github.com/flipped-aurora/gin-vue-admin/server/router" + _ "gin_server_admin/docs" + "gin_server_admin/global" + "gin_server_admin/middleware" + "gin_server_admin/router" "github.com/gin-gonic/gin" ginSwagger "github.com/swaggo/gin-swagger" "github.com/swaggo/gin-swagger/swaggerFiles" @@ -163,9 +163,9 @@ func Routers() *gin.Engine { // groupHandleRouter.InitGroupRouter(PrivateGroup) //集团架构 // groupHandleRouter.InitHealthReporRouter(PrivateGroup) //健康上报 - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. autocodeRouter.InitSysAutoCodeExampleRouter(PrivateGroup) - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. } //自定义登录验证 diff --git a/initialize/timer.go b/initialize/timer.go index 62c8185..b78cd77 100644 --- a/initialize/timer.go +++ b/initialize/timer.go @@ -3,9 +3,9 @@ package initialize import ( "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/config" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/config" + "gin_server_admin/global" + "gin_server_admin/utils" ) func Timer() { diff --git a/initialize/validator.go b/initialize/validator.go index 79aea66..17d0832 100644 --- a/initialize/validator.go +++ b/initialize/validator.go @@ -1,6 +1,6 @@ package initialize -import "github.com/flipped-aurora/gin-vue-admin/server/utils" +import "gin_server_admin/utils" func init() { _ = utils.RegisterRule("PageVerify", diff --git a/main.go b/main.go index 005f000..edcae66 100644 --- a/main.go +++ b/main.go @@ -3,10 +3,10 @@ package main import ( "fmt" - "github.com/flipped-aurora/gin-vue-admin/server/core" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/initialize" - "github.com/flipped-aurora/gin-vue-admin/server/scheduledtask" + "gin_server_admin/core" + "gin_server_admin/global" + "gin_server_admin/initialize" + "gin_server_admin/scheduledtask" ) //go:generate go env -w GO111MODULE=on diff --git a/middleware/casbin_rbac.go b/middleware/casbin_rbac.go index b21345e..25241d4 100644 --- a/middleware/casbin_rbac.go +++ b/middleware/casbin_rbac.go @@ -1,10 +1,10 @@ package middleware import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/service" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/service" + "gin_server_admin/utils" "github.com/gin-gonic/gin" ) diff --git a/middleware/email.go b/middleware/email.go index 3f10db6..a46c1c3 100644 --- a/middleware/email.go +++ b/middleware/email.go @@ -1,15 +1,15 @@ package middleware import ( - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/utils" - utils2 "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/plugin/email/utils" + utils2 "gin_server_admin/utils" "io/ioutil" "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/service" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/service" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/middleware/error.go b/middleware/error.go index f68b7a5..e0840ce 100644 --- a/middleware/error.go +++ b/middleware/error.go @@ -8,7 +8,7 @@ import ( "runtime/debug" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/middleware/jwt.go b/middleware/jwt.go index 576a3da..9bea871 100644 --- a/middleware/jwt.go +++ b/middleware/jwt.go @@ -1,14 +1,14 @@ package middleware import ( - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/utils" "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/service" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/system" + "gin_server_admin/service" "github.com/gin-gonic/gin" "go.uber.org/zap" diff --git a/middleware/limit_ip.go b/middleware/limit_ip.go index 9e95141..ef251cd 100644 --- a/middleware/limit_ip.go +++ b/middleware/limit_ip.go @@ -8,8 +8,8 @@ import ( "go.uber.org/zap" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/global" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/middleware/myjwt.go b/middleware/myjwt.go index 9f1097b..eefe5e8 100644 --- a/middleware/myjwt.go +++ b/middleware/myjwt.go @@ -5,17 +5,17 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/model/hrsystem" - "github.com/flipped-aurora/gin-vue-admin/server/service" - "github.com/flipped-aurora/gin-vue-admin/server/utils/redishandel" + "gin_server_admin/commonus" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + "gin_server_admin/model/hrsystem" + "gin_server_admin/service" + "gin_server_admin/utils/redishandel" "github.com/gin-gonic/gin" "github.com/mitchellh/mapstructure" ) -//鉴权 +// 鉴权 func MyAuthentication() gin.HandlerFunc { return func(c *gin.Context) { // userKey := c.Request.Header.Get("user-key") @@ -214,7 +214,7 @@ func SystemInterceptor() gin.HandlerFunc { } } -//扫码登录身份验证 +// 扫码登录身份验证 func ScanCodeLogin() gin.HandlerFunc { return func(c *gin.Context) { userKey := c.Request.Header.Get("user-key") @@ -228,6 +228,7 @@ func ScanCodeLogin() gin.HandlerFunc { } redisFileKey := "ScanCode:Authentication:LoginApi_" + global.GVA_CONFIG.RedisPrefix.Alias + "_" + userKey + fmt.Printf("userKey-------------->%v--------redisFileKey-------------->%v\n", userKey, redisFileKey) // userKeyInt, userKeyIntErr := strconv.ParseInt(userKey, 10, 64) // if userKeyIntErr != nil { @@ -244,7 +245,7 @@ func ScanCodeLogin() gin.HandlerFunc { var myCustomIdentify commonus.ScanCodeLogin if isTrues != true { - response.FailWithDetailed(gin.H{"reload": true, "code": 1002, "key": redisFileKey, "tokenInfo": tokenInfo, "redisClient": redisClient}, "您的帐户异地登陆或令牌失效", c) + response.FailWithDetailed(gin.H{"reload": true, "code": 1002, "key": redisFileKey, "tokenInfo": tokenInfo, "redisClient": redisClient, "userKey": userKey}, "您的帐户异地登陆或令牌失效", c) c.Abort() return } else { diff --git a/middleware/need_init.go b/middleware/need_init.go index 2a68720..42ec542 100644 --- a/middleware/need_init.go +++ b/middleware/need_init.go @@ -1,8 +1,8 @@ package middleware import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" + "gin_server_admin/global" + "gin_server_admin/model/common/response" "github.com/gin-gonic/gin" ) diff --git a/middleware/operation.go b/middleware/operation.go index 9e4b6c1..48ef328 100644 --- a/middleware/operation.go +++ b/middleware/operation.go @@ -2,15 +2,15 @@ package middleware import ( "bytes" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/utils" "io/ioutil" "net/http" "strconv" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/service" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/service" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/model/archivesmodel/archives.go b/model/archivesmodel/archives.go index 1144c4c..f394e22 100644 --- a/model/archivesmodel/archives.go +++ b/model/archivesmodel/archives.go @@ -3,11 +3,11 @@ package archivesmodel import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/commonus" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/commonus" + "gin_server_admin/global" ) -//文档分类相关 +// 文档分类相关 type ArchivesType struct { Id int64 `json:"id" gorm:"column:at_id;type:bigint(20) unsigned;not null;comment:Id"` Title string `json:"title" gorm:"column:at_title;type:varchar(255);comment:档案分类名称"` @@ -22,13 +22,13 @@ func (ArchivesType *ArchivesType) TableName() string { return "archives_type" } -//获取文档详细信息 +// 获取文档详细信息 func (a *ArchivesType) GetArchiveTypeInfo() (err error) { err = global.GVA_DB_Master.Where("at_id = ?", a.Id).First(&a).Error return } -//文档列表 +// 文档列表 type ArchiveFile struct { Id int64 `json:"id" gorm:"column:g_id;type:bigint(20) unsigned;not null;comment:Id"` Title string `json:"title" gorm:"column:g_title;type:varchar(255);not null;comment:标题"` @@ -70,7 +70,7 @@ func (ArchiveFile *ArchiveFile) TableName() string { return "graphicform" } -//初始化表单 +// 初始化表单 func (a *ArchiveFile) InitInfo() { a.Id = commonus.GetFileNumberEs() a.Title = "" @@ -108,13 +108,13 @@ func (a *ArchiveFile) InitInfo() { a.OuterLink = "" } -//获取文档详细信息 +// 获取文档详细信息 func (a *ArchiveFile) GetArchiveFileInfo() (err error) { err = global.GVA_DB_BooImgkDate.Where("g_id = ?", a.Id).First(&a).Error return } -//文档属性 +// 文档属性 type BookAttribute struct { Id int64 `json:"id" gorm:"column:b_id;type:bigint(20) unsigned;not null;autoIncrement;index;comment:Id"` FileId int64 `json:"fileId" gorm:"column:b_file_id;type:bigint(20) unsigned;default:0;not null;comment:文档ID"` @@ -130,13 +130,13 @@ func (brchiveFile *BookAttribute) TableName() string { return "bookattribute" } -//获取文档详细信息 +// 获取文档详细信息 func (b *BookAttribute) GetBookAttributeInfo() (err error) { err = global.GVA_DB_BooImgkDate.Where("b_id = ?", b.Id).First(&b).Error return } -//评论列表 +// 评论列表 type DiscussMsg struct { Id int64 `json:"id" gorm:"column:dis_id;type:bigint(20) unsigned;not null;comment:Id"` FileId int64 `json:"fileId" gorm:"column:dis_file_id;type:bigint(20) unsigned;default:0;not null;comment:文档ID"` @@ -154,7 +154,7 @@ func (DiscussMsg *DiscussMsg) TableName() string { return "discussmsg" } -//获取文档详细信息 +// 获取文档详细信息 func (d *DiscussMsg) GetDiscussMsgInfo() (err error) { err = global.GVA_DB_BooImgkDate.Where("b_id = ?", d.Id).First(&d).Error return diff --git a/model/assessmentmodel/dutyclass.go b/model/assessmentmodel/dutyclass.go index 5ff30cb..ec2cd36 100644 --- a/model/assessmentmodel/dutyclass.go +++ b/model/assessmentmodel/dutyclass.go @@ -3,7 +3,7 @@ package assessmentmodel import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 考核维度 diff --git a/model/assessmentmodel/performance_appraisal.go b/model/assessmentmodel/performance_appraisal.go index 0a3d8c5..ecda512 100644 --- a/model/assessmentmodel/performance_appraisal.go +++ b/model/assessmentmodel/performance_appraisal.go @@ -3,10 +3,10 @@ package assessmentmodel import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//分数流水 +// 分数流水 type ScoreFlow struct { Id int64 `json:"id" gorm:"primaryKey;column:sf_id;type:bigint(20) unsigned;not null;comment:Id"` EvaluationPlan int64 `json:"evaluationplan" gorm:"column:sf_evaluation_plan;type:bigint(20) unsigned;default:0;not null;comment:考核方案项目ID"` @@ -41,7 +41,7 @@ func (ScoreFlow *ScoreFlow) TableName() string { return "score_flow" } -//划分责任 division_responsibilities +// 划分责任 division_responsibilities type DivisionResponsibilities struct { Id int64 `json:"id" gorm:"primaryKey;column:df_id;type:bigint(20) unsigned;not null"` ScoreFlow int64 `json:"scoreflow" gorm:"column:df_sf_id;type:bigint(20) unsigned;default:0;not null;comment:归属加减分关联值"` @@ -64,7 +64,7 @@ func (DivisionResponsibilities *DivisionResponsibilities) TableName() string { return "division_responsibilities" } -//流程步进器 +// 流程步进器 type EvaluationProcess struct { Id int64 `json:"id" gorm:"primaryKey;column:ep_id;type:bigint(20) unsigned;not null"` OrderKey int64 `json:"orderkey" gorm:"column:ep_order_key;type:bigint(20) unsigned;default:0;not null;comment:发起表单key"` @@ -90,7 +90,7 @@ func (EvaluationProcess *EvaluationProcess) TableName() string { return "evaluation_process" } -//整改单具 +// 整改单具 type RectificationMeasures struct { Id int64 `json:"id" gorm:"primaryKey;column:rm_id;type:bigint(20) unsigned;not null"` UserKey int64 `json:"userkey" gorm:"column:rm_user_key;type:bigint(20) unsigned;default:0;not null;comment:整改人"` @@ -108,7 +108,7 @@ func (RectificationMeasures *RectificationMeasures) TableName() string { return "rectification_measures" } -//挂号 +// 挂号 type Register struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null"` Number int64 `json:"userkey" gorm:"column:number;type:bigint(20) unsigned;default:0;not null;comment:号码"` @@ -120,19 +120,19 @@ func (Register *Register) TableName() string { return "register" } -//添加 +// 添加 func (r *Register) AddCont() (err error) { err = global.GVA_DB_Performanceappraisal.Create(&r).Error return } -//编辑内容 +// 编辑内容 func (r *Register) EiteCont(whereMap interface{}, saveData interface{}) (err error) { err = global.GVA_DB_Performanceappraisal.Model(&r).Where(whereMap).Updates(saveData).Error return } -//获取内容 +// 获取内容 func (r *Register) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_Performanceappraisal.Model(&r) if len(field) > 0 { diff --git a/model/assessmentmodel/post_sun_target.go b/model/assessmentmodel/post_sun_target.go index d6adcee..9ef23cd 100644 --- a/model/assessmentmodel/post_sun_target.go +++ b/model/assessmentmodel/post_sun_target.go @@ -3,10 +3,10 @@ package assessmentmodel import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//岗位定性指标子栏目 +// 岗位定性指标子栏目 type PostSunTarget struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Title string `json:"title" gorm:"column:title;type:varchar(255) unsigned;default:'';not null;comment:标题"` @@ -21,14 +21,14 @@ func (PostSunTarget *PostSunTarget) TableName() string { return "post_sun_target" } -//编辑职务分类内容 +// 编辑职务分类内容 func (cont *PostSunTarget) EditCont(whereMap map[string]interface{}, saveData map[string]interface{}) (err error) { err = global.GVA_DB_Performanceappraisal.Model(&cont).Where(whereMap).Updates(saveData).Error return } -//获取详细内容 +// 获取详细内容 func (cont *PostSunTarget) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_Performanceappraisal.Model(&cont) if len(field) > 0 { @@ -40,7 +40,7 @@ func (cont *PostSunTarget) GetCont(whereMap interface{}, field ...string) (err e return } -//删除内容 +// 删除内容 func (cont *PostSunTarget) DelCont(whereMap interface{}) (err error) { err = global.GVA_DB_Performanceappraisal.Where(whereMap).Delete(&cont).Error return diff --git a/model/assessmentmodel/post_target.go b/model/assessmentmodel/post_target.go index 1ed9cfb..3cc7cb5 100644 --- a/model/assessmentmodel/post_target.go +++ b/model/assessmentmodel/post_target.go @@ -3,10 +3,10 @@ package assessmentmodel import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//岗位指标 +// 岗位指标 type PostTarget struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Title string `json:"title" gorm:"column:title;type:varchar(255) unsigned;default:'';not null;comment:标题"` @@ -31,14 +31,14 @@ func (PostTarget *PostTarget) TableName() string { return "post_target" } -//编辑职务分类内容 +// 编辑职务分类内容 func (cont *PostTarget) EditCont(whereMap map[string]interface{}, saveData map[string]interface{}) (err error) { err = global.GVA_DB_Performanceappraisal.Model(&cont).Where(whereMap).Updates(saveData).Error return } -//获取详细内容 +// 获取详细内容 func (cont *PostTarget) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_Performanceappraisal.Model(&cont) if len(field) > 0 { @@ -50,7 +50,7 @@ func (cont *PostTarget) GetCont(whereMap interface{}, field ...string) (err erro return } -//删除内容 +// 删除内容 func (cont *PostTarget) DelCont(whereMap interface{}) (err error) { err = global.GVA_DB_Performanceappraisal.Where(whereMap).Delete(&cont).Error return diff --git a/model/assessmentmodel/post_target_details.go b/model/assessmentmodel/post_target_details.go index a282548..ef48d7d 100644 --- a/model/assessmentmodel/post_target_details.go +++ b/model/assessmentmodel/post_target_details.go @@ -3,7 +3,7 @@ package assessmentmodel import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 指标细则 diff --git a/model/autocode/autocodeExample.go b/model/autocode/autocodeExample.go index 425e504..9df7d94 100644 --- a/model/autocode/autocodeExample.go +++ b/model/autocode/autocodeExample.go @@ -2,7 +2,7 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 如果含有time.Time 请自行import time包 diff --git a/model/autocode/request/autocodeExample.go b/model/autocode/request/autocodeExample.go index d048a98..f126d79 100644 --- a/model/autocode/request/autocodeExample.go +++ b/model/autocode/request/autocodeExample.go @@ -2,8 +2,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" + "gin_server_admin/model/autocode" + "gin_server_admin/model/common/request" ) // 如果含有time.Time 请自行import time包 diff --git a/model/example/exa_breakpoint_continue.go b/model/example/exa_breakpoint_continue.go index 3c2924b..f936ef5 100644 --- a/model/example/exa_breakpoint_continue.go +++ b/model/example/exa_breakpoint_continue.go @@ -1,7 +1,7 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // file struct, 文件结构体 diff --git a/model/example/exa_customer.go b/model/example/exa_customer.go index a4929ef..03b01e8 100644 --- a/model/example/exa_customer.go +++ b/model/example/exa_customer.go @@ -1,8 +1,8 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" ) type ExaCustomer struct { diff --git a/model/example/exa_excel.go b/model/example/exa_excel.go index fa96569..3350439 100644 --- a/model/example/exa_excel.go +++ b/model/example/exa_excel.go @@ -1,6 +1,6 @@ package example -import "github.com/flipped-aurora/gin-vue-admin/server/model/system" +import "gin_server_admin/model/system" type ExcelInfo struct { FileName string `json:"fileName"` // 文件名 diff --git a/model/example/exa_file_upload_download.go b/model/example/exa_file_upload_download.go index 6f74bb4..7ab82ff 100644 --- a/model/example/exa_file_upload_download.go +++ b/model/example/exa_file_upload_download.go @@ -1,7 +1,7 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) type ExaFileUploadAndDownload struct { diff --git a/model/example/response/exa_breakpoint_continue.go b/model/example/response/exa_breakpoint_continue.go index 54aa351..a7b1532 100644 --- a/model/example/response/exa_breakpoint_continue.go +++ b/model/example/response/exa_breakpoint_continue.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/example" +import "gin_server_admin/model/example" type FilePathResponse struct { FilePath string `json:"filePath"` diff --git a/model/example/response/exa_customer.go b/model/example/response/exa_customer.go index 7fd26f9..a02dc6e 100644 --- a/model/example/response/exa_customer.go +++ b/model/example/response/exa_customer.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/example" +import "gin_server_admin/model/example" type ExaCustomerResponse struct { Customer example.ExaCustomer `json:"customer"` diff --git a/model/example/response/exa_file_upload_download.go b/model/example/response/exa_file_upload_download.go index c1b7931..ffddcbe 100644 --- a/model/example/response/exa_file_upload_download.go +++ b/model/example/response/exa_file_upload_download.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/example" +import "gin_server_admin/model/example" type ExaFileResponse struct { File example.ExaFileUploadAndDownload `json:"file"` diff --git a/model/hrsystem/administrative_organization.go b/model/hrsystem/administrative_organization.go index f264f41..9fb04ee 100644 --- a/model/hrsystem/administrative_organization.go +++ b/model/hrsystem/administrative_organization.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//行政组织 +// 行政组织 type AdministrativeOrganization struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Number string `json:"number" gorm:"column:number;type:varchar(50) unsigned;default:'';not null;comment:行政编码"` @@ -27,13 +27,13 @@ func (AdministrativeOrganization *AdministrativeOrganization) TableName() string return "administrative_organization" } -//编辑行政组织内容 +// 编辑行政组织内容 func (cont *AdministrativeOrganization) EiteCont(whereMap map[string]interface{}, saveData map[string]interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Updates(saveData).Error return } -//获取行政组织内容 +// 获取行政组织内容 func (cont *AdministrativeOrganization) GetCont(whereMap map[string]interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { @@ -45,7 +45,7 @@ func (cont *AdministrativeOrganization) GetCont(whereMap map[string]interface{}, return } -//根据条件获取总数 +// 根据条件获取总数 func (cont *AdministrativeOrganization) CountCont(whereMap map[string]interface{}) (countId int64) { global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Count(&countId) return diff --git a/model/hrsystem/administrative_organization_type.go b/model/hrsystem/administrative_organization_type.go index 501963f..4d940e9 100644 --- a/model/hrsystem/administrative_organization_type.go +++ b/model/hrsystem/administrative_organization_type.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//行政组织类型 +// 行政组织类型 type AdministrativeOrganizationType struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Name string `json:"name" gorm:"column:name;type:varchar(255) unsigned;default:'';not null;comment:类型名称"` @@ -19,13 +19,13 @@ func (AdministrativeOrganizationType *AdministrativeOrganizationType) TableName( return "administrative_organization_type" } -//编辑职务分类内容 +// 编辑职务分类内容 func (cont *AdministrativeOrganizationType) EiteCont(whereMap interface{}, saveData map[string]interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Updates(saveData).Error return } -//获取详细内容 +// 获取详细内容 func (cont *AdministrativeOrganizationType) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/double_worker.go b/model/hrsystem/double_worker.go index f2de517..1598b73 100644 --- a/model/hrsystem/double_worker.go +++ b/model/hrsystem/double_worker.go @@ -1,10 +1,10 @@ package hrsystem import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//紧急联系人 +// 紧急联系人 type DoubleWorker struct { Number string `json:"number" gorm:"primaryKey;column:number;type:varchar(30) unsigned;not null;comment:员工工号;index"` Name string `json:"name" gorm:"column:name;type:varchar(255) unsigned;default:'';not null;comment:姓名"` @@ -19,7 +19,7 @@ func (DoubleWorker *DoubleWorker) TableName() string { return "double_worker" } -//编辑职务分类内容 +// 编辑职务分类内容 func (DoubleWorker *DoubleWorker) EiteCont(whereMap interface{}, saveData interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&DoubleWorker).Where(whereMap).Updates(saveData).Error return diff --git a/model/hrsystem/duties.go b/model/hrsystem/duties.go index 4b6584d..1c84ad5 100644 --- a/model/hrsystem/duties.go +++ b/model/hrsystem/duties.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //职务 type Duties struct { diff --git a/model/hrsystem/emergency_contact.go b/model/hrsystem/emergency_contact.go index 1f751d7..50912bd 100644 --- a/model/hrsystem/emergency_contact.go +++ b/model/hrsystem/emergency_contact.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //紧急联系人 type EmergencyContact struct { diff --git a/model/hrsystem/family_members.go b/model/hrsystem/family_members.go index 4cc57de..e15f0a0 100644 --- a/model/hrsystem/family_members.go +++ b/model/hrsystem/family_members.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //员工家属 type FamilyMembers struct { diff --git a/model/hrsystem/job_class.go b/model/hrsystem/job_class.go index 8351338..3bdb9e0 100644 --- a/model/hrsystem/job_class.go +++ b/model/hrsystem/job_class.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //职务分类 type JobClass struct { diff --git a/model/hrsystem/man_cont.go b/model/hrsystem/man_cont.go index 1aa81a4..2f3b15e 100644 --- a/model/hrsystem/man_cont.go +++ b/model/hrsystem/man_cont.go @@ -3,7 +3,7 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) type ManCont struct { @@ -64,7 +64,7 @@ func (ManCont *ManCont) TableName() string { return "man_cont" } -//获取职务分类内容 +// 获取职务分类内容 func (cont *ManCont) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/personarchives.go b/model/hrsystem/personarchives.go index 3c4186c..6e0b7f3 100644 --- a/model/hrsystem/personarchives.go +++ b/model/hrsystem/personarchives.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//员工档案(主) +// 员工档案(主) type PersonArchives struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:ID"` Number string `json:"number" gorm:"column:number;type:varchar(30) unsigned;not null;comment:员工工号"` @@ -43,13 +43,13 @@ func (PersonArchives *PersonArchives) TableName() string { return "person_archives" } -//编辑员工档案 +// 编辑员工档案 func (PersonArchives *PersonArchives) EiteCont(whereMap interface{}, saveData interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&PersonArchives).Where(whereMap).Updates(saveData).Error return } -//获取员工档案 +// 获取员工档案 func (cont *PersonArchives) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/personnel.go b/model/hrsystem/personnel.go index 62d55b0..d67bad2 100644 --- a/model/hrsystem/personnel.go +++ b/model/hrsystem/personnel.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//员工档案(主) +// 员工档案(主) type Personnel struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:ID"` Number string `json:"number" gorm:"column:number;type:varchar(30) unsigned;not null;comment:员工工号"` @@ -36,13 +36,13 @@ func (Personnel *Personnel) TableName() string { return "personnel" } -//编辑员工档案 +// 编辑员工档案 func (Personnel *Personnel) EiteCont(whereMap interface{}, saveData interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&Personnel).Where(whereMap).Updates(saveData).Error return } -//获取员工档案 +// 获取员工档案 func (cont *Personnel) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/personnel_change_record.go b/model/hrsystem/personnel_change_record.go index f3a41cf..17da147 100644 --- a/model/hrsystem/personnel_change_record.go +++ b/model/hrsystem/personnel_change_record.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //人员变动记录 type PersonnelChangeRecord struct { diff --git a/model/hrsystem/personnel_content.go b/model/hrsystem/personnel_content.go index 866669d..4324328 100644 --- a/model/hrsystem/personnel_content.go +++ b/model/hrsystem/personnel_content.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //员工附属信息 diff --git a/model/hrsystem/personnel_education.go b/model/hrsystem/personnel_education.go index 590b3b7..251fbca 100644 --- a/model/hrsystem/personnel_education.go +++ b/model/hrsystem/personnel_education.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //教育经历 diff --git a/model/hrsystem/position.go b/model/hrsystem/position.go index a44c8b7..868e2a1 100644 --- a/model/hrsystem/position.go +++ b/model/hrsystem/position.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//职位(岗位) +// 职位(岗位) type Position struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Number string `json:"number" gorm:"column:number;type:varchar(50) unsigned;default:'';not null;comment:职位编码"` @@ -27,13 +27,13 @@ func (Position *Position) TableName() string { return "position" } -//编辑职务分类内容 +// 编辑职务分类内容 func (cont *Position) EiteCont(whereMap interface{}, saveData interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Updates(saveData).Error return } -//获取行政组织内容 +// 获取行政组织内容 func (cont *Position) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { @@ -45,7 +45,7 @@ func (cont *Position) GetCont(whereMap interface{}, field ...string) (err error) return } -//根据条件获取总数 +// 根据条件获取总数 func (cont *Position) CountCont(whereMap interface{}) (countId int64) { global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Count(&countId) return diff --git a/model/hrsystem/position_level.go b/model/hrsystem/position_level.go index e35e33d..0c7fe7b 100644 --- a/model/hrsystem/position_level.go +++ b/model/hrsystem/position_level.go @@ -1,6 +1,6 @@ package hrsystem -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //职位等级 type PositionLevel struct { diff --git a/model/hrsystem/post_duties_job.go b/model/hrsystem/post_duties_job.go index 94b26bf..90ae404 100644 --- a/model/hrsystem/post_duties_job.go +++ b/model/hrsystem/post_duties_job.go @@ -3,7 +3,7 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) //职务与岗位视图 @@ -32,7 +32,7 @@ func (PostDutiesJob *PostDutiesJob) TableName() string { return "post_duties_job" } -//获取详细内容 +// 获取详细内容 func (cont *PostDutiesJob) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/system_nenu.go b/model/hrsystem/system_nenu.go index b6e11a1..347735f 100644 --- a/model/hrsystem/system_nenu.go +++ b/model/hrsystem/system_nenu.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//菜单 +// 菜单 type SystemMenu struct { Id int64 `json:"id" gorm:"primaryKey;column:m_id;type:bigint(20) unsigned;not null;comment:ID"` Title string `json:"title" gorm:"column:m_title;type:varchar(255);not null;comment:菜单名称"` @@ -23,19 +23,19 @@ func (SystemMenu *SystemMenu) TableName() string { return "system_menu" } -//菜单管理 +// 菜单管理 type SystemMenuOperation struct { SystemMenu MenuPermit []MenuOperation `json:"menupermit"` } -//根据条件获取总数 +// 根据条件获取总数 func (cont *SystemMenu) CountCont(whereMap map[string]interface{}) (countId int64) { global.GVA_DB_HrDataBase.Model(&cont).Where(whereMap).Count(&countId) return } -//获取行政组织内容 +// 获取行政组织内容 func (cont *SystemMenu) GetCont(whereMap map[string]interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/hrsystem/teamgroup.go b/model/hrsystem/teamgroup.go index 655ea26..935922a 100644 --- a/model/hrsystem/teamgroup.go +++ b/model/hrsystem/teamgroup.go @@ -3,10 +3,10 @@ package hrsystem import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) -//班组 +// 班组 type TeamGroup struct { Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Name string `json:"name" gorm:"column:name;type:varchar(255) unsigned;default:'';not null;comment:班组名称"` @@ -18,13 +18,13 @@ func (TeamGroup *TeamGroup) TableName() string { return "teamgroup" } -//编辑班组内容 +// 编辑班组内容 func (TeamGroup *TeamGroup) EiteTeamGroupCont(whereMap map[string]interface{}, saveData map[string]interface{}) (err error) { err = global.GVA_DB_HrDataBase.Model(&TeamGroup).Where(whereMap).Updates(saveData).Error return } -//获取详细内容 +// 获取详细内容 func (cont *TeamGroup) GetCont(whereMap interface{}, field ...string) (err error) { gormDb := global.GVA_DB_HrDataBase.Model(&cont) if len(field) > 0 { diff --git a/model/system/request/sys_api.go b/model/system/request/sys_api.go index 0be8ee7..b20be78 100644 --- a/model/system/request/sys_api.go +++ b/model/system/request/sys_api.go @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" ) // api分页条件查询及排序结构体 diff --git a/model/system/request/sys_autocode.go b/model/system/request/sys_autocode.go index 7216d91..9a8f6f0 100644 --- a/model/system/request/sys_autocode.go +++ b/model/system/request/sys_autocode.go @@ -1,6 +1,6 @@ package request -import "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" +import "gin_server_admin/model/common/request" type SysAutoHistory struct { request.PageInfo diff --git a/model/system/request/sys_dictionary.go b/model/system/request/sys_dictionary.go index 170ed60..5dddfae 100644 --- a/model/system/request/sys_dictionary.go +++ b/model/system/request/sys_dictionary.go @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" ) type SysDictionarySearch struct { diff --git a/model/system/request/sys_dictionary_detail.go b/model/system/request/sys_dictionary_detail.go index 2f97da2..b9d7548 100644 --- a/model/system/request/sys_dictionary_detail.go +++ b/model/system/request/sys_dictionary_detail.go @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" ) type SysDictionaryDetailSearch struct { diff --git a/model/system/request/sys_menu.go b/model/system/request/sys_menu.go index 2e785c2..4a77d94 100644 --- a/model/system/request/sys_menu.go +++ b/model/system/request/sys_menu.go @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" ) // Add menu authority info structure diff --git a/model/system/request/sys_operation_record.go b/model/system/request/sys_operation_record.go index e58dd59..0c2575e 100644 --- a/model/system/request/sys_operation_record.go +++ b/model/system/request/sys_operation_record.go @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" ) type SysOperationRecordSearch struct { diff --git a/model/system/response/sys_api.go b/model/system/response/sys_api.go index 09dc72f..edeff23 100644 --- a/model/system/response/sys_api.go +++ b/model/system/response/sys_api.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/system" +import "gin_server_admin/model/system" type SysAPIResponse struct { Api system.SysApi `json:"api"` diff --git a/model/system/response/sys_authority.go b/model/system/response/sys_authority.go index 7eaaaca..6245e92 100644 --- a/model/system/response/sys_authority.go +++ b/model/system/response/sys_authority.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/system" +import "gin_server_admin/model/system" type SysAuthorityResponse struct { Authority system.SysAuthority `json:"authority"` diff --git a/model/system/response/sys_casbin.go b/model/system/response/sys_casbin.go index 267bb42..cb3e292 100644 --- a/model/system/response/sys_casbin.go +++ b/model/system/response/sys_casbin.go @@ -1,7 +1,7 @@ package response import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/model/system/request" ) type PolicyPathResponse struct { diff --git a/model/system/response/sys_menu.go b/model/system/response/sys_menu.go index d8f80f3..8081a78 100644 --- a/model/system/response/sys_menu.go +++ b/model/system/response/sys_menu.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/model/system" +import "gin_server_admin/model/system" type SysMenusResponse struct { Menus []system.SysMenu `json:"menus"` diff --git a/model/system/response/sys_system.go b/model/system/response/sys_system.go index f19e965..679a4c0 100644 --- a/model/system/response/sys_system.go +++ b/model/system/response/sys_system.go @@ -1,6 +1,6 @@ package response -import "github.com/flipped-aurora/gin-vue-admin/server/config" +import "gin_server_admin/config" type SysConfigResponse struct { Config config.Server `json:"config"` diff --git a/model/system/response/sys_user.go b/model/system/response/sys_user.go index d6f1074..c6e7c02 100644 --- a/model/system/response/sys_user.go +++ b/model/system/response/sys_user.go @@ -1,7 +1,7 @@ package response import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/model/system" ) type SysUserResponse struct { diff --git a/model/system/sys_api.go b/model/system/sys_api.go index 731efc4..0f53b07 100644 --- a/model/system/sys_api.go +++ b/model/system/sys_api.go @@ -1,7 +1,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) type SysApi struct { diff --git a/model/system/sys_autocode_history.go b/model/system/sys_autocode_history.go index 2250cb3..13e7fd9 100644 --- a/model/system/sys_autocode_history.go +++ b/model/system/sys_autocode_history.go @@ -1,6 +1,6 @@ package system -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" // 自动迁移代码记录,用于回滚,重放使用 diff --git a/model/system/sys_base_menu.go b/model/system/sys_base_menu.go index 9a655c4..878dfa8 100644 --- a/model/system/sys_base_menu.go +++ b/model/system/sys_base_menu.go @@ -1,7 +1,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) type SysBaseMenu struct { diff --git a/model/system/sys_dictionary.go b/model/system/sys_dictionary.go index b5af59a..533e8b1 100644 --- a/model/system/sys_dictionary.go +++ b/model/system/sys_dictionary.go @@ -2,7 +2,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 如果含有time.Time 请自行import time包 diff --git a/model/system/sys_dictionary_detail.go b/model/system/sys_dictionary_detail.go index f443080..8a68175 100644 --- a/model/system/sys_dictionary_detail.go +++ b/model/system/sys_dictionary_detail.go @@ -2,7 +2,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 如果含有time.Time 请自行import time包 diff --git a/model/system/sys_jwt_blacklist.go b/model/system/sys_jwt_blacklist.go index 4f9fa39..efb790c 100644 --- a/model/system/sys_jwt_blacklist.go +++ b/model/system/sys_jwt_blacklist.go @@ -1,7 +1,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) type JwtBlacklist struct { diff --git a/model/system/sys_operation_record.go b/model/system/sys_operation_record.go index 43bf756..7f61b03 100644 --- a/model/system/sys_operation_record.go +++ b/model/system/sys_operation_record.go @@ -4,7 +4,7 @@ package system import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // 如果含有time.Time 请自行import time包 diff --git a/model/system/sys_system.go b/model/system/sys_system.go index ad98311..8cddb90 100644 --- a/model/system/sys_system.go +++ b/model/system/sys_system.go @@ -1,7 +1,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/config" + "gin_server_admin/config" ) // 配置文件结构体 diff --git a/model/system/sys_user.go b/model/system/sys_user.go index 40678cd..bbda5f6 100644 --- a/model/system/sys_user.go +++ b/model/system/sys_user.go @@ -1,7 +1,7 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/satori/go.uuid" ) diff --git a/model/systemuser/systemuser.go b/model/systemuser/systemuser.go index 0f98dbe..868bbfe 100644 --- a/model/systemuser/systemuser.go +++ b/model/systemuser/systemuser.go @@ -1,6 +1,6 @@ package systemuser -import "github.com/flipped-aurora/gin-vue-admin/server/global" +import "gin_server_admin/global" //系统用户表 type SystemUser struct { diff --git a/model/testpage/grouptree.go b/model/testpage/grouptree.go index 045dc79..a78636d 100644 --- a/model/testpage/grouptree.go +++ b/model/testpage/grouptree.go @@ -3,13 +3,13 @@ package testpage import ( "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) //企业微信架构 -//分厂于工段 -//分厂 +// 分厂于工段 +// 分厂 type BranchFactory struct { Id int64 `json:"id" gorm:"column:bf_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:bf_name;type:varchar(30);not null;comment:分厂名称"` //'分厂名称', @@ -21,7 +21,7 @@ type BranchFactory struct { WechatId int `json:"wechatid" gorm:"column:bf_wechat_id;type:int(4) unsigned;default:0;not null;comment:对照微信id"` //'对照微信id', } -//分厂关联 +// 分厂关联 type BranchFactoryHasMany struct { Id int64 `json:"id" gorm:"column:bf_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:bf_name;type:varchar(30);not null;comment:分厂名称"` //'分厂名称', @@ -34,7 +34,7 @@ type BranchFactoryHasMany struct { WorkshopSectionStruct []WorkShopsection `gorm:"foreignKey:ws_bf_id";references:"bf_id"` } -//工段 +// 工段 type WorkShopsection struct { Id int64 `json:"id" gorm:"column:ws_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:ws_name;type:varchar(50);not null;comment:工段名称"` //'工段名称', @@ -79,7 +79,7 @@ func (cont *WorkShopsection) GetCont(whereMap map[string]interface{}, field ...s return } -//职务 +// 职务 type Position struct { Id int64 `json:"id" gorm:"column:ps_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:ps_name;type:varchar(50);not null;comment:工段名称"` //工段名称 @@ -98,7 +98,7 @@ func (Position *Position) TableName() string { return "position" } -//班组 +// 班组 type Teaming struct { Id int64 `json:"id" gorm:"column:tm_id;type:bigint(20);;primaryKey;unique;not null;autoIncrement;index"` Name string `json:"name" gorm:"column:tm_name;type:varchar(50);not null;comment:班组名称"` diff --git a/plugin/email/api/sys_email.go b/plugin/email/api/sys_email.go index 03e13af..1f10634 100644 --- a/plugin/email/api/sys_email.go +++ b/plugin/email/api/sys_email.go @@ -1,10 +1,10 @@ package api import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - email_response "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/model/response" - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/service" + "gin_server_admin/global" + "gin_server_admin/model/common/response" + email_response "gin_server_admin/plugin/email/model/response" + "gin_server_admin/plugin/email/service" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/plugin/email/global/gloabl.go b/plugin/email/global/gloabl.go index 13082d0..f179c71 100644 --- a/plugin/email/global/gloabl.go +++ b/plugin/email/global/gloabl.go @@ -1,5 +1,5 @@ package global -import "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/config" +import "gin_server_admin/plugin/email/config" var GlobalConfig = new(config.Email) diff --git a/plugin/email/main.go b/plugin/email/main.go index e044797..471ec6b 100644 --- a/plugin/email/main.go +++ b/plugin/email/main.go @@ -1,8 +1,8 @@ package email import ( - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/global" - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/router" + "gin_server_admin/plugin/email/global" + "gin_server_admin/plugin/email/router" "github.com/gin-gonic/gin" ) diff --git a/plugin/email/router/sys_email.go b/plugin/email/router/sys_email.go index 518bb0b..2b12087 100644 --- a/plugin/email/router/sys_email.go +++ b/plugin/email/router/sys_email.go @@ -1,8 +1,8 @@ package router import ( - "github.com/flipped-aurora/gin-vue-admin/server/middleware" - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/api" + "gin_server_admin/middleware" + "gin_server_admin/plugin/email/api" "github.com/gin-gonic/gin" ) diff --git a/plugin/email/service/sys_email.go b/plugin/email/service/sys_email.go index 6659fc6..cce79d7 100644 --- a/plugin/email/service/sys_email.go +++ b/plugin/email/service/sys_email.go @@ -1,7 +1,7 @@ package service import ( - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/utils" + "gin_server_admin/plugin/email/utils" ) type EmailService struct { diff --git a/plugin/email/utils/email.go b/plugin/email/utils/email.go index 986b90f..ae7e3d4 100644 --- a/plugin/email/utils/email.go +++ b/plugin/email/utils/email.go @@ -6,7 +6,7 @@ import ( "net/smtp" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/plugin/email/global" + "gin_server_admin/plugin/email/global" "github.com/jordan-wright/email" ) diff --git a/resource/template/readme.txt.tpl b/resource/template/readme.txt.tpl index 25de230..d2d41b7 100644 --- a/resource/template/readme.txt.tpl +++ b/resource/template/readme.txt.tpl @@ -2,6 +2,6 @@ 后端代码解压后同理,放到自己想要的 mvc对应路径 并且到 initRouter中注册自动生成的路由 到registerTable中注册自动生成的model -项目github:"https://github.com/piexlmax/github.com/flipped-aurora/gin-vue-admin/server" +项目github:"https://github.com/piexlmax/gin_server_admin" 希望大家给个star多多鼓励 diff --git a/resource/template/server/api.go.tpl b/resource/template/server/api.go.tpl index 42dcad6..33235b7 100644 --- a/resource/template/server/api.go.tpl +++ b/resource/template/server/api.go.tpl @@ -1,12 +1,12 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - autocodeReq "github.com/flipped-aurora/gin-vue-admin/server/model/autocode/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/response" - "github.com/flipped-aurora/gin-vue-admin/server/service" + "gin_server_admin/global" + "gin_server_admin/model/autocode" + "gin_server_admin/model/common/request" + autocodeReq "gin_server_admin/model/autocode/request" + "gin_server_admin/model/common/response" + "gin_server_admin/service" "github.com/gin-gonic/gin" "go.uber.org/zap" ) diff --git a/resource/template/server/model.go.tpl b/resource/template/server/model.go.tpl index fbad1e0..898846c 100644 --- a/resource/template/server/model.go.tpl +++ b/resource/template/server/model.go.tpl @@ -2,7 +2,7 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) // {{.StructName}} 结构体 diff --git a/resource/template/server/request.go.tpl b/resource/template/server/request.go.tpl index 262b55c..4574e17 100644 --- a/resource/template/server/request.go.tpl +++ b/resource/template/server/request.go.tpl @@ -1,8 +1,8 @@ package request import ( - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" + "gin_server_admin/model/autocode" + "gin_server_admin/model/common/request" ) type {{.StructName}}Search struct{ diff --git a/resource/template/server/router.go.tpl b/resource/template/server/router.go.tpl index 85f0f2b..1f569e1 100644 --- a/resource/template/server/router.go.tpl +++ b/resource/template/server/router.go.tpl @@ -1,8 +1,8 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/resource/template/server/service.go.tpl b/resource/template/server/service.go.tpl index 2fc99f1..1aaaf90 100644 --- a/resource/template/server/service.go.tpl +++ b/resource/template/server/service.go.tpl @@ -1,10 +1,10 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - autoCodeReq "github.com/flipped-aurora/gin-vue-admin/server/model/autocode/request" + "gin_server_admin/global" + "gin_server_admin/model/autocode" + "gin_server_admin/model/common/request" + autoCodeReq "gin_server_admin/model/autocode/request" ) type {{.StructName}}Service struct { diff --git a/router/archive/archiverouter.go b/router/archive/archiverouter.go index 8c5d3a9..a2222df 100644 --- a/router/archive/archiverouter.go +++ b/router/archive/archiverouter.go @@ -1,7 +1,7 @@ package archive import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/assessment/assessmentrouter.go b/router/assessment/assessmentrouter.go index c1938f4..eee3e24 100644 --- a/router/assessment/assessmentrouter.go +++ b/router/assessment/assessmentrouter.go @@ -1,8 +1,8 @@ package assessment import ( - v2 "github.com/flipped-aurora/gin-vue-admin/server/api/index" - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v2 "gin_server_admin/api/index" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) @@ -142,7 +142,7 @@ func (s *AssessmentRouter) InitDutyHandelRouter(Router *gin.RouterGroup) { } } -//无需验证 +// 无需验证 func (s *AssessmentRouter) NoInitDutyHandelRouter(Router *gin.RouterGroup) { dutyIndexCodeRouter := Router.Group("noverify") var authorityIndexApi = v2.ApiGroupApp.AssessMentApi.Assessment @@ -177,7 +177,7 @@ func (s *AssessmentRouter) InitEvaluationSchemeRouter(Router *gin.RouterGroup) { } -//用户端数据考核 +// 用户端数据考核 func (s *AssessmentRouter) InitEvaluationRouter(Router *gin.RouterGroup) { dutyIndexCodeRouter := Router.Group("eval") var authorityIndexApi = v2.ApiGroupApp.EvaluationApi.EvaluationApi diff --git a/router/autocode/autocodeExample.go b/router/autocode/autocodeExample.go index 981b5fa..e241762 100644 --- a/router/autocode/autocodeExample.go +++ b/router/autocode/autocodeExample.go @@ -1,8 +1,8 @@ package autocode import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/autocode/enter.go b/router/autocode/enter.go index c8c71d6..e11081f 100644 --- a/router/autocode/enter.go +++ b/router/autocode/enter.go @@ -1,7 +1,7 @@ package autocode type RouterGroup struct { - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. AutoCodeExampleRouter - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. } diff --git a/router/enter.go b/router/enter.go index 67e40cd..45c5012 100644 --- a/router/enter.go +++ b/router/enter.go @@ -1,26 +1,26 @@ package router import ( - "github.com/flipped-aurora/gin-vue-admin/server/router/archive" - "github.com/flipped-aurora/gin-vue-admin/server/router/assessment" - "github.com/flipped-aurora/gin-vue-admin/server/router/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/router/example" - "github.com/flipped-aurora/gin-vue-admin/server/router/examrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/examtestpage" - "github.com/flipped-aurora/gin-vue-admin/server/router/index/examapprove" - "github.com/flipped-aurora/gin-vue-admin/server/router/index/statisticsroute" - "github.com/flipped-aurora/gin-vue-admin/server/router/postrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/publichandel" - "github.com/flipped-aurora/gin-vue-admin/server/router/replyrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/shiyan" - "github.com/flipped-aurora/gin-vue-admin/server/router/staffrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/statisticsrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/system" - "github.com/flipped-aurora/gin-vue-admin/server/router/systemadmin" - "github.com/flipped-aurora/gin-vue-admin/server/router/uploaddownload" - "github.com/flipped-aurora/gin-vue-admin/server/router/webrouter" - "github.com/flipped-aurora/gin-vue-admin/server/router/wechatapp" - "github.com/flipped-aurora/gin-vue-admin/server/router/wechatcallbackrouter" + "gin_server_admin/router/archive" + "gin_server_admin/router/assessment" + "gin_server_admin/router/autocode" + "gin_server_admin/router/example" + "gin_server_admin/router/examrouter" + "gin_server_admin/router/examtestpage" + "gin_server_admin/router/index/examapprove" + "gin_server_admin/router/index/statisticsroute" + "gin_server_admin/router/postrouter" + "gin_server_admin/router/publichandel" + "gin_server_admin/router/replyrouter" + "gin_server_admin/router/shiyan" + "gin_server_admin/router/staffrouter" + "gin_server_admin/router/statisticsrouter" + "gin_server_admin/router/system" + "gin_server_admin/router/systemadmin" + "gin_server_admin/router/uploaddownload" + "gin_server_admin/router/webrouter" + "gin_server_admin/router/wechatapp" + "gin_server_admin/router/wechatcallbackrouter" ) type RouterGroup struct { diff --git a/router/example/exa_customer.go b/router/example/exa_customer.go index dd5db6f..e3aab1d 100644 --- a/router/example/exa_customer.go +++ b/router/example/exa_customer.go @@ -1,8 +1,8 @@ package example import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/example/exa_excel.go b/router/example/exa_excel.go index b964793..554020d 100644 --- a/router/example/exa_excel.go +++ b/router/example/exa_excel.go @@ -1,7 +1,7 @@ package example import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/example/exa_file_upload_and_download.go b/router/example/exa_file_upload_and_download.go index c650866..b029dc8 100644 --- a/router/example/exa_file_upload_and_download.go +++ b/router/example/exa_file_upload_and_download.go @@ -1,7 +1,7 @@ package example import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/examrouter/exam.go b/router/examrouter/exam.go index a4d08fe..2f98968 100644 --- a/router/examrouter/exam.go +++ b/router/examrouter/exam.go @@ -1,7 +1,7 @@ package examrouter import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/examrouter/ques.go b/router/examrouter/ques.go index fb818eb..50d75f9 100644 --- a/router/examrouter/ques.go +++ b/router/examrouter/ques.go @@ -1,11 +1,11 @@ package examrouter import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) -//试题相关 +// 试题相关 type QuestionsRouter struct{} func (e *QuestionsRouter) InitGroupRouter(Router *gin.RouterGroup) { diff --git a/router/examtestpage/grouphandle.go b/router/examtestpage/grouphandle.go index 26afc8b..c34b6d8 100644 --- a/router/examtestpage/grouphandle.go +++ b/router/examtestpage/grouphandle.go @@ -1,11 +1,11 @@ package examtestpage import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) -//集团框架相关处理数据 +// 集团框架相关处理数据 type GroupHandleRouter struct{} func (g *GroupHandleRouter) InitGroupRouter(Router *gin.RouterGroup) { diff --git a/router/examtestpage/healthreporthandle.go b/router/examtestpage/healthreporthandle.go index 05c706e..3401c44 100644 --- a/router/examtestpage/healthreporthandle.go +++ b/router/examtestpage/healthreporthandle.go @@ -1,7 +1,7 @@ package examtestpage import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/index/examapprove/examapprouter.go b/router/index/examapprove/examapprouter.go index 45051d8..e5e4da3 100644 --- a/router/index/examapprove/examapprouter.go +++ b/router/index/examapprove/examapprouter.go @@ -1,13 +1,13 @@ package examapprove import ( - v2 "github.com/flipped-aurora/gin-vue-admin/server/api/index" + v2 "gin_server_admin/api/index" "github.com/gin-gonic/gin" ) type ExamApproveRouter struct{} -//审批 +// 审批 func (s *ExamApproveRouter) InitShiyanRouter(Router *gin.RouterGroup) { shiyanCodeRouter := Router.Group("examine") var authorityApi = v2.ApiGroupApp.ExamApproveApi.ExamineApproveApi diff --git a/router/index/statisticsroute/programme.go b/router/index/statisticsroute/programme.go index 2c095a7..3bda588 100644 --- a/router/index/statisticsroute/programme.go +++ b/router/index/statisticsroute/programme.go @@ -1,7 +1,7 @@ package statisticsroute import ( - v2 "github.com/flipped-aurora/gin-vue-admin/server/api/index" + v2 "gin_server_admin/api/index" "github.com/gin-gonic/gin" ) diff --git a/router/postrouter/post_target.go b/router/postrouter/post_target.go index 0d6b6c5..382130e 100644 --- a/router/postrouter/post_target.go +++ b/router/postrouter/post_target.go @@ -1,7 +1,7 @@ package postrouter import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/publichandel/geography.go b/router/publichandel/geography.go index c69437e..89e8863 100644 --- a/router/publichandel/geography.go +++ b/router/publichandel/geography.go @@ -1,7 +1,7 @@ package publichandel import ( - public "github.com/flipped-aurora/gin-vue-admin/server/api/publichandle" + public "gin_server_admin/api/publichandle" "github.com/gin-gonic/gin" ) diff --git a/router/replyrouter/enter.go b/router/replyrouter/enter.go index 33ad6f2..c8de640 100644 --- a/router/replyrouter/enter.go +++ b/router/replyrouter/enter.go @@ -1,7 +1,7 @@ package replyrouter import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/reply" + "gin_server_admin/api/reply" "github.com/gin-gonic/gin" ) diff --git a/router/shiyan/sys_shiyan.go b/router/shiyan/sys_shiyan.go index 0b10e78..11af169 100644 --- a/router/shiyan/sys_shiyan.go +++ b/router/shiyan/sys_shiyan.go @@ -1,7 +1,8 @@ package shiyan import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" + "github.com/gin-gonic/gin" ) @@ -56,6 +57,7 @@ func (s *ShiyanRouter) InitShiyanRouter(Router *gin.RouterGroup) { shiyanCodeRouter.POST("correctingorg", authorityApi.CorrectingOrg) //校正行政组织 shiyanCodeRouter.POST("delflowdatauser", authorityApi.DelFlowDataUser) //删除人员提交数据 shiyanCodeRouter.POST("dingliangpass", authorityApi.DingLiangPass) //处理定量没有审批流的数据 - shiyanCodeRouter.POST("dingxingpass", authorityApi.DingXingPass) //定性考核没有审批流的数据 + shiyanCodeRouter.POST("dingxingpass", authorityApi.DingXingPass) //定性考核没有审批流的数据 ShiyanPinYin + shiyanCodeRouter.POST("shiyanpinyin", authorityApi.ShiyanPinYin) } } diff --git a/router/staffrouter/people.go b/router/staffrouter/people.go index 8ebd2fa..e305da2 100644 --- a/router/staffrouter/people.go +++ b/router/staffrouter/people.go @@ -1,7 +1,7 @@ package staffrouter import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/statisticsrouter/statistics.go b/router/statisticsrouter/statistics.go index 7aa1626..5f2c2be 100644 --- a/router/statisticsrouter/statistics.go +++ b/router/statisticsrouter/statistics.go @@ -1,7 +1,7 @@ package statisticsrouter import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/statistics" + "gin_server_admin/api/statistics" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_admin.go b/router/system/sys_admin.go index e8999cc..93822d3 100644 --- a/router/system/sys_admin.go +++ b/router/system/sys_admin.go @@ -1,7 +1,7 @@ package system import ( - adminApi "github.com/flipped-aurora/gin-vue-admin/server/api/admin" + adminApi "gin_server_admin/api/admin" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_api.go b/router/system/sys_api.go index 6420382..7c470ac 100644 --- a/router/system/sys_api.go +++ b/router/system/sys_api.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_authority.go b/router/system/sys_authority.go index 07787e9..11d185c 100644 --- a/router/system/sys_authority.go +++ b/router/system/sys_authority.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_auto_code.go b/router/system/sys_auto_code.go index af1edae..a958c68 100644 --- a/router/system/sys_auto_code.go +++ b/router/system/sys_auto_code.go @@ -1,7 +1,7 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_base.go b/router/system/sys_base.go index 4996207..ca31490 100644 --- a/router/system/sys_base.go +++ b/router/system/sys_base.go @@ -1,7 +1,7 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_casbin.go b/router/system/sys_casbin.go index 618444c..e4a7190 100644 --- a/router/system/sys_casbin.go +++ b/router/system/sys_casbin.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_dictionary.go b/router/system/sys_dictionary.go index 2a9e89e..a09435f 100644 --- a/router/system/sys_dictionary.go +++ b/router/system/sys_dictionary.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_dictionary_detail.go b/router/system/sys_dictionary_detail.go index c9a4d8b..1c87b33 100644 --- a/router/system/sys_dictionary_detail.go +++ b/router/system/sys_dictionary_detail.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_initdb.go b/router/system/sys_initdb.go index 69d3bf7..746bee3 100644 --- a/router/system/sys_initdb.go +++ b/router/system/sys_initdb.go @@ -1,7 +1,7 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_jwt.go b/router/system/sys_jwt.go index 68713cd..b9b427f 100644 --- a/router/system/sys_jwt.go +++ b/router/system/sys_jwt.go @@ -1,7 +1,7 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_menu.go b/router/system/sys_menu.go index ecac638..94e138a 100644 --- a/router/system/sys_menu.go +++ b/router/system/sys_menu.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_operation_record.go b/router/system/sys_operation_record.go index 647fdb4..16d2892 100644 --- a/router/system/sys_operation_record.go +++ b/router/system/sys_operation_record.go @@ -1,7 +1,7 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_system.go b/router/system/sys_system.go index 67b982b..216edd9 100644 --- a/router/system/sys_system.go +++ b/router/system/sys_system.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/system/sys_user.go b/router/system/sys_user.go index d520379..e0bd377 100644 --- a/router/system/sys_user.go +++ b/router/system/sys_user.go @@ -1,8 +1,8 @@ package system import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" - "github.com/flipped-aurora/gin-vue-admin/server/middleware" + v1 "gin_server_admin/api/v1" + "gin_server_admin/middleware" "github.com/gin-gonic/gin" ) diff --git a/router/systemadmin/dutyassess.go b/router/systemadmin/dutyassess.go index 043700b..ccbf84e 100644 --- a/router/systemadmin/dutyassess.go +++ b/router/systemadmin/dutyassess.go @@ -1,7 +1,7 @@ package systemadmin import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/admin" + v1 "gin_server_admin/api/admin" "github.com/gin-gonic/gin" ) diff --git a/router/systemadmin/groupmanagement.go b/router/systemadmin/groupmanagement.go index 4f82a6f..4667ec6 100644 --- a/router/systemadmin/groupmanagement.go +++ b/router/systemadmin/groupmanagement.go @@ -1,7 +1,7 @@ package systemadmin import ( - sysAdmin "github.com/flipped-aurora/gin-vue-admin/server/api/admin" + sysAdmin "gin_server_admin/api/admin" "github.com/gin-gonic/gin" ) diff --git a/router/uploaddownload/fileuplaoddown.go b/router/uploaddownload/fileuplaoddown.go index fceb412..74136dc 100644 --- a/router/uploaddownload/fileuplaoddown.go +++ b/router/uploaddownload/fileuplaoddown.go @@ -1,7 +1,7 @@ package uploaddownload import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/router/webrouter/webrouter.go b/router/webrouter/webrouter.go index 746f91c..9562f6d 100644 --- a/router/webrouter/webrouter.go +++ b/router/webrouter/webrouter.go @@ -1,7 +1,7 @@ package webrouter import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/web" + "gin_server_admin/api/web" "github.com/gin-gonic/gin" ) diff --git a/router/wechatapp/callback.go b/router/wechatapp/callback.go index b6bfa5e..ad792bf 100644 --- a/router/wechatapp/callback.go +++ b/router/wechatapp/callback.go @@ -1,11 +1,11 @@ package wechatapp import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp" + "gin_server_admin/api/wechatapp" "github.com/gin-gonic/gin" ) -//企业微信回调路由 +// 企业微信回调路由 type CallBackWeCahtApi struct{} func (g *CallBackWeCahtApi) InitGroupRouter(Router *gin.RouterGroup) { diff --git a/router/wechatapp/sendmsg.go b/router/wechatapp/sendmsg.go index c2f678a..cde74ef 100644 --- a/router/wechatapp/sendmsg.go +++ b/router/wechatapp/sendmsg.go @@ -1,11 +1,11 @@ package wechatapp import ( - "github.com/flipped-aurora/gin-vue-admin/server/api/wechatapp" + "gin_server_admin/api/wechatapp" "github.com/gin-gonic/gin" ) -//向企业微信发送信息路由 +// 向企业微信发送信息路由 type SendMsgWeCahtApi struct{} func (g *SendMsgWeCahtApi) InitGroupRouter(Router *gin.RouterGroup) { diff --git a/router/wechatcallbackrouter/wechatcallbackhandle.go b/router/wechatcallbackrouter/wechatcallbackhandle.go index 868dfb3..b774ef5 100644 --- a/router/wechatcallbackrouter/wechatcallbackhandle.go +++ b/router/wechatcallbackrouter/wechatcallbackhandle.go @@ -1,7 +1,7 @@ package wechatcallbackrouter import ( - v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1" + v1 "gin_server_admin/api/v1" "github.com/gin-gonic/gin" ) diff --git a/server.exe b/server.exe index 3f7c4aa..3ca290c 100644 Binary files a/server.exe and b/server.exe differ diff --git a/service/autocode/autocodeExample.go b/service/autocode/autocodeExample.go index 3f6e620..9349b99 100644 --- a/service/autocode/autocodeExample.go +++ b/service/autocode/autocodeExample.go @@ -1,9 +1,9 @@ package autocode import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/model/autocode/request" + "gin_server_admin/global" + "gin_server_admin/model/autocode" + "gin_server_admin/model/autocode/request" ) type AutoCodeExampleService struct { diff --git a/service/autocode/enter.go b/service/autocode/enter.go index 9f4db68..524ce69 100644 --- a/service/autocode/enter.go +++ b/service/autocode/enter.go @@ -1,7 +1,7 @@ package autocode type ServiceGroup struct { - // Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT. + // Code generated by gin_server_admin Begin; DO NOT EDIT. AutoCodeExampleService - // Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT. + // Code generated by gin_server_admin End; DO NOT EDIT. } diff --git a/service/enter.go b/service/enter.go index 045acb6..81f6a8c 100644 --- a/service/enter.go +++ b/service/enter.go @@ -1,9 +1,9 @@ package service import ( - "github.com/flipped-aurora/gin-vue-admin/server/service/autocode" - "github.com/flipped-aurora/gin-vue-admin/server/service/example" - "github.com/flipped-aurora/gin-vue-admin/server/service/system" + "gin_server_admin/service/autocode" + "gin_server_admin/service/example" + "gin_server_admin/service/system" ) type ServiceGroup struct { diff --git a/service/example/exa_breakpoint_continue.go b/service/example/exa_breakpoint_continue.go index afce53b..7aa03b1 100644 --- a/service/example/exa_breakpoint_continue.go +++ b/service/example/exa_breakpoint_continue.go @@ -3,8 +3,8 @@ package example import ( "errors" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" + "gin_server_admin/global" + "gin_server_admin/model/example" "gorm.io/gorm" ) diff --git a/service/example/exa_customer.go b/service/example/exa_customer.go index b191eba..cd69dbd 100644 --- a/service/example/exa_customer.go +++ b/service/example/exa_customer.go @@ -1,11 +1,11 @@ package example import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemService "github.com/flipped-aurora/gin-vue-admin/server/service/system" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/example" + "gin_server_admin/model/system" + systemService "gin_server_admin/service/system" ) type CustomerService struct { diff --git a/service/example/exa_excel_parse.go b/service/example/exa_excel_parse.go index e444c1f..a753dee 100644 --- a/service/example/exa_excel_parse.go +++ b/service/example/exa_excel_parse.go @@ -5,8 +5,8 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/xuri/excelize/v2" ) diff --git a/service/example/exa_file_upload_download.go b/service/example/exa_file_upload_download.go index 122cb6b..a3b2556 100644 --- a/service/example/exa_file_upload_download.go +++ b/service/example/exa_file_upload_download.go @@ -5,10 +5,10 @@ import ( "mime/multipart" "strings" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - "github.com/flipped-aurora/gin-vue-admin/server/utils/upload" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/example" + "gin_server_admin/utils/upload" ) //@author: [piexlmax](https://github.com/piexlmax) diff --git a/service/system/jwt_black_list.go b/service/system/jwt_black_list.go index 6a97619..8bbae24 100644 --- a/service/system/jwt_black_list.go +++ b/service/system/jwt_black_list.go @@ -5,8 +5,8 @@ import ( "go.uber.org/zap" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" ) type JwtService struct { diff --git a/service/system/sys_api.go b/service/system/sys_api.go index 7234a47..c76a17c 100644 --- a/service/system/sys_api.go +++ b/service/system/sys_api.go @@ -3,9 +3,9 @@ package system import ( "errors" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" "gorm.io/gorm" ) diff --git a/service/system/sys_authority.go b/service/system/sys_authority.go index d9925c7..b897aeb 100644 --- a/service/system/sys_authority.go +++ b/service/system/sys_authority.go @@ -4,10 +4,10 @@ import ( "errors" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/response" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" + "gin_server_admin/model/system/response" "gorm.io/gorm" ) diff --git a/service/system/sys_auto_code.go b/service/system/sys_auto_code.go index aa60514..d2ced5e 100644 --- a/service/system/sys_auto_code.go +++ b/service/system/sys_auto_code.go @@ -11,10 +11,10 @@ import ( "strings" "text/template" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" + "gin_server_admin/utils" "gorm.io/gorm" ) diff --git a/service/system/sys_autocode_history.go b/service/system/sys_autocode_history.go index 2e163e6..758445c 100644 --- a/service/system/sys_autocode_history.go +++ b/service/system/sys_autocode_history.go @@ -7,10 +7,10 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" + "gin_server_admin/utils" "go.uber.org/zap" ) diff --git a/service/system/sys_base_menu.go b/service/system/sys_base_menu.go index 2bdde5c..bb52189 100644 --- a/service/system/sys_base_menu.go +++ b/service/system/sys_base_menu.go @@ -3,8 +3,8 @@ package system import ( "errors" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "gorm.io/gorm" ) diff --git a/service/system/sys_casbin.go b/service/system/sys_casbin.go index c583ab0..80fc6b9 100644 --- a/service/system/sys_casbin.go +++ b/service/system/sys_casbin.go @@ -5,12 +5,12 @@ import ( "strings" "sync" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" "github.com/casbin/casbin/v2" "github.com/casbin/casbin/v2/util" gormadapter "github.com/casbin/gorm-adapter/v3" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" _ "github.com/go-sql-driver/mysql" ) diff --git a/service/system/sys_dictionary.go b/service/system/sys_dictionary.go index 4dfc960..e599fd3 100644 --- a/service/system/sys_dictionary.go +++ b/service/system/sys_dictionary.go @@ -3,9 +3,9 @@ package system import ( "errors" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" "gorm.io/gorm" ) diff --git a/service/system/sys_dictionary_detail.go b/service/system/sys_dictionary_detail.go index f227b5e..4d27111 100644 --- a/service/system/sys_dictionary_detail.go +++ b/service/system/sys_dictionary_detail.go @@ -1,9 +1,9 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" ) //@author: [piexlmax](https://github.com/piexlmax) diff --git a/service/system/sys_initdb.go b/service/system/sys_initdb.go index 25b03fb..91cfb2e 100644 --- a/service/system/sys_initdb.go +++ b/service/system/sys_initdb.go @@ -7,13 +7,13 @@ import ( uuid "github.com/satori/go.uuid" - "github.com/flipped-aurora/gin-vue-admin/server/config" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" - "github.com/flipped-aurora/gin-vue-admin/server/source" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/config" + "gin_server_admin/global" + "gin_server_admin/model/example" + "gin_server_admin/model/system" + "gin_server_admin/model/system/request" + "gin_server_admin/source" + "gin_server_admin/utils" "github.com/spf13/viper" "gorm.io/driver/mysql" diff --git a/service/system/sys_menu.go b/service/system/sys_menu.go index 7c3e1eb..f8db02a 100644 --- a/service/system/sys_menu.go +++ b/service/system/sys_menu.go @@ -5,9 +5,9 @@ import ( "fmt" "strconv" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" "gorm.io/gorm" ) diff --git a/service/system/sys_operation_record.go b/service/system/sys_operation_record.go index 9e7e6a0..a8238e4 100644 --- a/service/system/sys_operation_record.go +++ b/service/system/sys_operation_record.go @@ -1,10 +1,10 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" + systemReq "gin_server_admin/model/system/request" ) //@author: [granty1](https://github.com/granty1) diff --git a/service/system/sys_system.go b/service/system/sys_system.go index a9853ef..8d93460 100644 --- a/service/system/sys_system.go +++ b/service/system/sys_system.go @@ -1,10 +1,10 @@ package system import ( - "github.com/flipped-aurora/gin-vue-admin/server/config" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/config" + "gin_server_admin/global" + "gin_server_admin/model/system" + "gin_server_admin/utils" "go.uber.org/zap" ) diff --git a/service/system/sys_user.go b/service/system/sys_user.go index 9942d72..d3eeefc 100644 --- a/service/system/sys_user.go +++ b/service/system/sys_user.go @@ -3,10 +3,10 @@ package system import ( "errors" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/common/request" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/model/common/request" + "gin_server_admin/model/system" + "gin_server_admin/utils" uuid "github.com/satori/go.uuid" "gorm.io/gorm" ) diff --git a/source/admin.go b/source/admin.go index 713035a..353154b 100644 --- a/source/admin.go +++ b/source/admin.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" uuid "github.com/satori/go.uuid" @@ -20,8 +20,8 @@ var admins = []system.SysUser{ {GVA_MODEL: global.GVA_MODEL{ID: 2, CreatedAt: time.Now(), UpdatedAt: time.Now()}, UUID: uuid.NewV4(), Username: "a303176530", Password: "3ec063004a6f31642261936a379fde3d", NickName: "QMPlusUser", HeaderImg: "https:///qmplusimg.henrongyi.top/1572075907logo.png", AuthorityId: "9528"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_users 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_users 表数据初始化 func (a *admin) Init() error { return global.GVA_DB.Transaction(func(tx *gorm.DB) error { if tx.Where("id IN ?", []int{1, 2}).Find(&[]system.SysUser{}).RowsAffected == 2 { diff --git a/source/api.go b/source/api.go index 69e8c9e..04411d2 100644 --- a/source/api.go +++ b/source/api.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" @@ -95,8 +95,8 @@ var apis = []system.SysApi{ {global.GVA_MODEL{ID: 91, CreatedAt: time.Now(), UpdatedAt: time.Now()}, "/user/getUserInfo", "获取自身信息(必选)", "user", "GET"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_apis 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_apis 表数据初始化 func (a *api) Init() error { return global.GVA_DB.Transaction(func(tx *gorm.DB) error { if tx.Where("id IN ?", []int{1, 67}).Find(&[]system.SysApi{}).RowsAffected == 2 { diff --git a/source/authorities_menus.go b/source/authorities_menus.go index d89af81..139d469 100644 --- a/source/authorities_menus.go +++ b/source/authorities_menus.go @@ -1,7 +1,7 @@ package source import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/gookit/color" "gorm.io/gorm" ) @@ -61,8 +61,8 @@ var authorityMenus = []AuthorityMenus{ {"9528", 17}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_authority_menus 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_authority_menus 表数据初始化 func (a *authoritiesMenus) Init() error { return global.GVA_DB.Table("sys_authority_menus").Transaction(func(tx *gorm.DB) error { if tx.Where("sys_authority_authority_id IN ('888', '8881', '9528')").Find(&[]AuthorityMenus{}).RowsAffected == 48 { diff --git a/source/authority.go b/source/authority.go index 716c029..5df0e4e 100644 --- a/source/authority.go +++ b/source/authority.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" @@ -20,8 +20,8 @@ var authorities = []system.SysAuthority{ {CreatedAt: time.Now(), UpdatedAt: time.Now(), AuthorityId: "9528", AuthorityName: "测试角色", ParentId: "0", DefaultRouter: "dashboard"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_authorities 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_authorities 表数据初始化 func (a *authority) Init() error { return global.GVA_DB.Transaction(func(tx *gorm.DB) error { if tx.Where("authority_id IN ? ", []string{"888", "9528"}).Find(&[]system.SysAuthority{}).RowsAffected == 2 { diff --git a/source/authority_menu.go b/source/authority_menu.go index 1579bfd..97cc4b7 100644 --- a/source/authority_menu.go +++ b/source/authority_menu.go @@ -1,8 +1,8 @@ package source import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" ) @@ -10,8 +10,8 @@ var AuthorityMenu = new(authorityMenu) type authorityMenu struct{} -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: authority_menu 视图数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: authority_menu 视图数据初始化 func (a *authorityMenu) Init() error { if global.GVA_DB.Migrator().HasTable("authority_menu") && global.GVA_DB.Find(&[]system.SysMenu{}).RowsAffected > 0 { color.Danger.Println("\n[Mysql] --> authority_menu 视图已存在!") diff --git a/source/casbin.go b/source/casbin.go index 18cbcd9..1ea7dd7 100644 --- a/source/casbin.go +++ b/source/casbin.go @@ -1,7 +1,7 @@ package source import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" gormadapter "github.com/casbin/gorm-adapter/v3" "github.com/gookit/color" @@ -171,8 +171,8 @@ var carbines = []gormadapter.CasbinRule{ {PType: "p", V0: "9528", V1: "/user/getUserInfo", V2: "GET"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: casbin_rule 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: casbin_rule 表数据初始化 func (c *casbin) Init() error { global.GVA_DB.AutoMigrate(gormadapter.CasbinRule{}) return global.GVA_DB.Transaction(func(tx *gorm.DB) error { diff --git a/source/data_authorities.go b/source/data_authorities.go index 840dc27..6fbc11b 100644 --- a/source/data_authorities.go +++ b/source/data_authorities.go @@ -1,7 +1,7 @@ package source import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/gookit/color" "gorm.io/gorm" @@ -24,8 +24,8 @@ var infos = []DataAuthority{ {"9528", "9528"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_data_authority_id 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_data_authority_id 表数据初始化 func (d *dataAuthorities) Init() error { return global.GVA_DB.Table("sys_data_authority_id").Transaction(func(tx *gorm.DB) error { if tx.Where("sys_authority_authority_id IN ('888', '9528') ").Find(&[]DataAuthority{}).RowsAffected == 5 { diff --git a/source/dictionary.go b/source/dictionary.go index 3dbc1bb..b000cb4 100644 --- a/source/dictionary.go +++ b/source/dictionary.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" @@ -16,8 +16,8 @@ type dictionary struct{} var status = new(bool) -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_dictionaries 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_dictionaries 表数据初始化 func (d *dictionary) Init() error { *status = true var dictionaries = []system.SysDictionary{ diff --git a/source/dictionary_details.go b/source/dictionary_details.go index 96066a3..b34c781 100644 --- a/source/dictionary_details.go +++ b/source/dictionary_details.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" @@ -14,8 +14,8 @@ var DictionaryDetail = new(dictionaryDetail) type dictionaryDetail struct{} -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: dictionary_details 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: dictionary_details 表数据初始化 func (d *dictionaryDetail) Init() error { var details = []system.SysDictionaryDetail{ {global.GVA_MODEL{ID: 1, CreatedAt: time.Now(), UpdatedAt: time.Now()}, "smallint", 1, status, 1, 2}, diff --git a/source/file.go b/source/file.go index 964383c..79f0076 100644 --- a/source/file.go +++ b/source/file.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/example" + "gin_server_admin/global" + "gin_server_admin/model/example" "github.com/gookit/color" "gorm.io/gorm" ) @@ -18,8 +18,8 @@ var files = []example.ExaFileUploadAndDownload{ {global.GVA_MODEL{ID: 2, CreatedAt: time.Now(), UpdatedAt: time.Now()}, "logo.png", "https://qmplusimg.henrongyi.top/1576554439myAvatar.png", "png", "1587973709logo.png"}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: exa_file_upload_and_downloads 表初始化数据 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: exa_file_upload_and_downloads 表初始化数据 func (f *file) Init() error { return global.GVA_DB.Transaction(func(tx *gorm.DB) error { if tx.Where("id IN ?", []int{1, 2}).Find(&[]example.ExaFileUploadAndDownload{}).RowsAffected == 2 { diff --git a/source/menu.go b/source/menu.go index 6901017..195633a 100644 --- a/source/menu.go +++ b/source/menu.go @@ -3,8 +3,8 @@ package source import ( "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" @@ -41,8 +41,8 @@ var menus = []system.SysBaseMenu{ {GVA_MODEL: global.GVA_MODEL{ID: 25, CreatedAt: time.Now(), UpdatedAt: time.Now()}, MenuLevel: 0, ParentId: "14", Path: "autoCodeEdit/:id", Name: "autoCodeEdit", Hidden: true, Component: "view/systemTools/autoCode/index.vue", Sort: 0, Meta: system.Meta{Title: "自动化代码(复用)", Icon: "s-finance"}}, } -//@author: [SliverHorn](https://github.com/SliverHorn) -//@description: sys_base_menus 表数据初始化 +// @author: [SliverHorn](https://github.com/SliverHorn) +// @description: sys_base_menus 表数据初始化 func (m *menu) Init() error { return global.GVA_DB.Transaction(func(tx *gorm.DB) error { if tx.Where("id IN ?", []int{1, 29}).Find(&[]system.SysBaseMenu{}).RowsAffected == 2 { diff --git a/source/user_authority.go b/source/user_authority.go index 2bcda6d..647735e 100644 --- a/source/user_authority.go +++ b/source/user_authority.go @@ -1,8 +1,8 @@ package source import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system" + "gin_server_admin/global" + "gin_server_admin/model/system" "github.com/gookit/color" "gorm.io/gorm" ) @@ -18,7 +18,7 @@ var userAuthorityModel = []system.SysUseAuthority{ {2, "888"}, } -//@description: user_authority 数据初始化 +// @description: user_authority 数据初始化 func (a *userAuthority) Init() error { return global.GVA_DB.Model(&system.SysUseAuthority{}).Transaction(func(tx *gorm.DB) error { if tx.Where("sys_user_id IN (1, 2)").Find(&[]system.SysUseAuthority{}).RowsAffected == 4 { diff --git a/utils/captcha/redis.go b/utils/captcha/redis.go index 3a679ef..fa39ca0 100644 --- a/utils/captcha/redis.go +++ b/utils/captcha/redis.go @@ -2,7 +2,7 @@ package captcha import ( "context" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/mojocn/base64Captcha" "go.uber.org/zap" "time" diff --git a/utils/clamis.go b/utils/clamis.go index b63919d..da6f833 100644 --- a/utils/clamis.go +++ b/utils/clamis.go @@ -1,28 +1,28 @@ package utils import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" - systemReq "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" + "gin_server_admin/global" + systemReq "gin_server_admin/model/system/request" "github.com/gin-gonic/gin" uuid "github.com/satori/go.uuid" ) -func GetClaims(c *gin.Context) (*systemReq.CustomClaims,error) { +func GetClaims(c *gin.Context) (*systemReq.CustomClaims, error) { token := c.Request.Header.Get("x-token") j := NewJWT() claims, err := j.ParseToken(token) if err != nil { global.GVA_LOG.Error("从Gin的Context中获取从jwt解析信息失败, 请检查请求头是否存在x-token且claims是否为规定结构") } - return claims,err + return claims, err } // 从Gin的Context中获取从jwt解析出来的用户ID func GetUserID(c *gin.Context) uint { if claims, exists := c.Get("claims"); !exists { - if cl,err:= GetClaims(c);err!=nil{ + if cl, err := GetClaims(c); err != nil { return 0 - }else{ + } else { return cl.ID } } else { @@ -35,9 +35,9 @@ func GetUserID(c *gin.Context) uint { // 从Gin的Context中获取从jwt解析出来的用户UUID func GetUserUuid(c *gin.Context) uuid.UUID { if claims, exists := c.Get("claims"); !exists { - if cl,err:= GetClaims(c);err!=nil{ + if cl, err := GetClaims(c); err != nil { return uuid.UUID{} - }else{ + } else { return cl.UUID } } else { @@ -49,9 +49,9 @@ func GetUserUuid(c *gin.Context) uuid.UUID { // 从Gin的Context中获取从jwt解析出来的用户角色id func GetUserAuthorityId(c *gin.Context) string { if claims, exists := c.Get("claims"); !exists { - if cl,err:= GetClaims(c);err!=nil{ + if cl, err := GetClaims(c); err != nil { return "" - }else{ + } else { return cl.AuthorityId } } else { @@ -63,9 +63,9 @@ func GetUserAuthorityId(c *gin.Context) string { // 从Gin的Context中获取从jwt解析出来的用户角色id func GetUserInfo(c *gin.Context) *systemReq.CustomClaims { if claims, exists := c.Get("claims"); !exists { - if cl,err:= GetClaims(c);err!=nil{ + if cl, err := GetClaims(c); err != nil { return nil - }else{ + } else { return cl } } else { diff --git a/utils/directory.go b/utils/directory.go index 9ae6cf4..69563ca 100644 --- a/utils/directory.go +++ b/utils/directory.go @@ -3,7 +3,7 @@ package utils import ( "os" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "go.uber.org/zap" ) diff --git a/utils/injectionCode.go b/utils/injectionCode.go index 66f17ec..9a904b0 100644 --- a/utils/injectionCode.go +++ b/utils/injectionCode.go @@ -17,8 +17,8 @@ import ( //@return: error const ( - startComment = "Code generated by github.com/flipped-aurora/gin-vue-admin/server Begin; DO NOT EDIT." - endComment = "Code generated by github.com/flipped-aurora/gin-vue-admin/server End; DO NOT EDIT." + startComment = "Code generated by gin_server_admin Begin; DO NOT EDIT." + endComment = "Code generated by gin_server_admin End; DO NOT EDIT." ) //@author: [LeonardWang](https://github.com/WangLeonard) diff --git a/utils/jwt.go b/utils/jwt.go index 196e44d..4759bac 100644 --- a/utils/jwt.go +++ b/utils/jwt.go @@ -2,9 +2,9 @@ package utils import ( "errors" + "gin_server_admin/global" + "gin_server_admin/model/system/request" "github.com/dgrijalva/jwt-go" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/model/system/request" "time" ) diff --git a/utils/redishandel/myredis.go b/utils/redishandel/myredis.go index a00b833..9144092 100644 --- a/utils/redishandel/myredis.go +++ b/utils/redishandel/myredis.go @@ -4,11 +4,11 @@ import ( "context" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/go-redis/redis/v8" ) -//redis 基础设定 +// redis 基础设定 type RedisStoreType struct { Expiration time.Duration PreKey string @@ -16,7 +16,7 @@ type RedisStoreType struct { RedisDb *redis.Client } -//启动redis +// 启动redis func RunRedis() *RedisStoreType { var redisStoreType RedisStoreType // contextBackground := context.Background() @@ -32,7 +32,7 @@ func RunRedis() *RedisStoreType { // } } -//选择其他数据库 +// 选择其他数据库 func (r *RedisStoreType) SetRedisDb(dbId int) { switch dbId { case 0: @@ -48,17 +48,17 @@ func (r *RedisStoreType) SetRedisDb(dbId int) { } } -//设置键前缀 +// 设置键前缀 func (r *RedisStoreType) SetRedisPrefix(prefix string) { r.PreKey = prefix } -//设置过期时间 +// 设置过期时间 func (r *RedisStoreType) SetRedisTime(timeDate int64) { r.Expiration = time.Second * time.Duration(timeDate) } -//设置字符串 +// 设置字符串 func (r *RedisStoreType) Set(key string, value string) bool { err := r.RedisDb.Set(r.Context, r.PreKey+key, value, r.Expiration).Err() if err != nil { @@ -67,7 +67,7 @@ func (r *RedisStoreType) Set(key string, value string) bool { return true } -//获取字符串 +// 获取字符串 func (r *RedisStoreType) Get(key string) (bool, string) { err := r.RedisDb.Get(r.Context, r.PreKey+key) if err.Err() != nil { @@ -76,7 +76,7 @@ func (r *RedisStoreType) Get(key string) (bool, string) { return true, err.Val() } -//删除键 +// 删除键 func (r *RedisStoreType) DelKey(key string) bool { err := r.RedisDb.Del(r.Context, r.PreKey+key).Err() if err != nil { @@ -180,7 +180,8 @@ func (r *RedisStoreType) HashGetAll(hashName string) (map[string]string, bool) { //Redis 列表(List) -/** +/* +* Linsert 命令用于在列表的元素前或者后插入元素。当指定元素不存在于列表中时,不执行任何操作。 当列表不存在时,被视为空列表,不执行任何操作。 如果 key 不是列表类型,返回一个错误。 @@ -201,7 +202,8 @@ func (r *RedisStoreType) Linsert(key string, op int, pivot, value interface{}) ( return linsert, true } -/** +/* +* Lindex 命令用于通过索引获取列表中的元素。你也可以使用负数下标,以 -1 表示列表的最后一个元素, -2 表示列表的倒数第二个元素,以此类推。 @key 列表 @index 索引 @@ -211,7 +213,8 @@ func (r *RedisStoreType) Lindex(key string, index int64) (val string, err error) return } -/** +/* +* Llen 命令用于返回列表的长度。 如果列表 key 不存在,则 key 被解释为一个空列表,返回 0 。 如果 key 不是列表类型,返回一个错误。 @key 列表 */ @@ -220,7 +223,8 @@ func (r *RedisStoreType) Llen(key string) (val int64, err error) { return } -/** +/* +* Lpop 命令用于移除并返回列表的第一个元素。 @key 列表 */ @@ -229,7 +233,8 @@ func (r *RedisStoreType) Lpop(key string) (val string, err error) { return } -/** +/* +* Lpush 命令将一个或多个值插入到列表头部。 如果 key 不存在,一个空列表会被创建并执行 LPUSH 操作。 当 key 存在但不是列表类型时,返回一个错误。 @key 列表 @value 要插入的字符串 @@ -239,7 +244,8 @@ func (r *RedisStoreType) Lpush(key string, value ...interface{}) (val int64, err return } -/** +/* +* Lpushx 将一个值插入到已存在的列表头部,列表不存在时操作无效。 @key 列表 @value 要插入的字符串 @@ -249,7 +255,8 @@ func (r *RedisStoreType) Lpushx(key, value string) (val int64, err error) { return } -/** +/* +* Lrange 返回列表中指定区间内的元素,区间以偏移量 START 和 END 指定。 其中 0 表示列表的第一个元素, 1 表示列表的第二个元素,以此类推。 你也可以使用负数下标,以 -1 表示列表的最后一个元素, -2 表示列表的倒数第二个元素,以此类推。 @key 列表 @start 起始值 @@ -260,12 +267,15 @@ func (r *RedisStoreType) Lrange(key string, start, stop int64) (val []string, er return } -/** +/* +* Lrem 根据参数 COUNT 的值,移除列表中与参数 VALUE 相等的元素。 COUNT 的值可以是以下几种: + count > 0 : 从表头开始向表尾搜索,移除与 VALUE 相等的元素,数量为 COUNT 。 count < 0 : 从表尾开始向表头搜索,移除与 VALUE 相等的元素,数量为 COUNT 的绝对值。 count = 0 : 移除表中所有与 VALUE 相等的值。 + @start = COUNT @key 列表 */ @@ -274,7 +284,8 @@ func (r *RedisStoreType) Lrem(key string, start int64, value ...interface{}) (va return } -/** +/* +* Redis Lset 通过索引来设置元素的值。 当索引参数超出范围,或对一个空列表进行 LSET 时,返回一个错误。 @@ -286,7 +297,8 @@ func (r *RedisStoreType) Lset(key string, indexes int64, value ...interface{}) ( return } -/** +/* +* Ltrim 对一个列表进行修剪(trim),就是说,让列表只保留指定区间内的元素,不在指定区间之内的元素都将被删除。 下标 0 表示列表的第一个元素,以 1 表示列表的第二个元素,以此类推。 你也可以使用负数下标,以 -1 表示列表的最后一个元素, -2 表示列表的倒数第二个元素,以此类推。 @@ -299,7 +311,8 @@ func (r *RedisStoreType) Ltrim(key string, start, stop int64) (val string, err e return } -/** +/* +* Rpop 命令用于移除列表的最后一个元素,返回值为移除的元素。 @key 列表 */ @@ -308,7 +321,8 @@ func (r *RedisStoreType) Rpop(key string) (val string, err error) { return } -/** +/* +* Rpoplpush 命令用于移除列表的最后一个元素,并将该元素添加到另一个列表并返回。 @sourceKey 源列表 @newKey 目标列表 @@ -318,7 +332,8 @@ func (r *RedisStoreType) Rpoplpush(sourceKey, newKey string) (val string, err er return } -/** +/* +* Rpush 命令用于将一个或多个值插入到列表的尾部(最右边)。 如果列表不存在,一个空列表会被创建并执行 RPUSH 操作。 当列表存在但不是列表类型时,返回一个错误。 @key 列表 @@ -329,7 +344,8 @@ func (r *RedisStoreType) Rpush(key string, value ...interface{}) (val int64, err return } -/** +/* +* Rpushx 命令用于将一个值插入到已存在的列表尾部(最右边)。如果列表不存在,操作无效。 @key 列表 @value 要插入的字符串 @@ -339,7 +355,8 @@ func (r *RedisStoreType) Rpushx(key string, value ...interface{}) (val int64, er return } -/** +/* +* Blpop 命令移出并获取列表的第一个元素, 如果列表没有元素会阻塞列表直到等待超时或发现可弹出元素为止。 @key 列表 */ @@ -348,7 +365,8 @@ func (r *RedisStoreType) Blpop(key string) (val []string, err error) { return } -/** +/* +* Brpop 命令移出并获取列表的最后一个元素, 如果列表没有元素会阻塞列表直到等待超时或发现可弹出元素为止。 @key 列表 */ @@ -357,7 +375,8 @@ func (r *RedisStoreType) Brpop(key string) (val []string, err error) { return } -/** +/* +* Brpoplpush 命令从列表中取出最后一个元素,并插入到另外一个列表的头部; 如果列表没有元素会阻塞列表直到等待超时或发现可弹出元素为止。 @source 源列表 @destination 目标列表 diff --git a/utils/rotatelogs.go b/utils/rotatelogs.go index ad20520..fef7109 100644 --- a/utils/rotatelogs.go +++ b/utils/rotatelogs.go @@ -1,7 +1,7 @@ package utils import ( - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/natefinch/lumberjack" "go.uber.org/zap/zapcore" "os" diff --git a/utils/upload/aliyun_oss.go b/utils/upload/aliyun_oss.go index 1e6a787..5c7387f 100644 --- a/utils/upload/aliyun_oss.go +++ b/utils/upload/aliyun_oss.go @@ -5,8 +5,8 @@ import ( "mime/multipart" "time" + "gin_server_admin/global" "github.com/aliyun/aliyun-oss-go-sdk/oss" - "github.com/flipped-aurora/gin-vue-admin/server/global" "go.uber.org/zap" ) diff --git a/utils/upload/local.go b/utils/upload/local.go index aa4dfe7..46f8d87 100644 --- a/utils/upload/local.go +++ b/utils/upload/local.go @@ -9,8 +9,8 @@ import ( "strings" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" - "github.com/flipped-aurora/gin-vue-admin/server/utils" + "gin_server_admin/global" + "gin_server_admin/utils" "go.uber.org/zap" ) diff --git a/utils/upload/qiniu.go b/utils/upload/qiniu.go index 4ac001a..8e6d4a9 100644 --- a/utils/upload/qiniu.go +++ b/utils/upload/qiniu.go @@ -7,7 +7,7 @@ import ( "mime/multipart" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/qiniu/api.v7/v7/auth/qbox" "github.com/qiniu/api.v7/v7/storage" "go.uber.org/zap" diff --git a/utils/upload/tencent_cos.go b/utils/upload/tencent_cos.go index a5b268b..daf81e8 100644 --- a/utils/upload/tencent_cos.go +++ b/utils/upload/tencent_cos.go @@ -9,7 +9,7 @@ import ( "net/url" "time" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" "github.com/tencentyun/cos-go-sdk-v5" "go.uber.org/zap" diff --git a/utils/upload/upload.go b/utils/upload/upload.go index d801522..d6c8f2d 100644 --- a/utils/upload/upload.go +++ b/utils/upload/upload.go @@ -3,7 +3,7 @@ package upload import ( "mime/multipart" - "github.com/flipped-aurora/gin-vue-admin/server/global" + "gin_server_admin/global" ) //@author: [ccfish86](https://github.com/ccfish86) diff --git a/其他支持文件/config.yaml b/其他支持文件/config.yaml index c6f7ee9..ca4287c 100644 --- a/其他支持文件/config.yaml +++ b/其他支持文件/config.yaml @@ -94,7 +94,7 @@ tencent-cos: secret-id: xxxxxxxx secret-key: xxxxxxxx base-url: https://gin.vue.admin - path-prefix: github.com/flipped-aurora/gin-vue-admin/server + path-prefix: gin_server_admin timer: start: true spec: '@daily' @@ -108,7 +108,7 @@ timer: zap: level: info format: console - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: log showLine: true encode-level: LowercaseColorLevelEncoder diff --git a/其他支持文件/config_2022.04.05.yaml b/其他支持文件/config_2022.04.05.yaml index 68b3bb0..fdc7de4 100644 --- a/其他支持文件/config_2022.04.05.yaml +++ b/其他支持文件/config_2022.04.05.yaml @@ -90,7 +90,7 @@ tencent-cos: secret-id: xxxxxxxx secret-key: xxxxxxxx base-url: https://gin.vue.admin - path-prefix: github.com/flipped-aurora/gin-vue-admin/server + path-prefix: gin_server_admin timer: start: true spec: '@daily' @@ -104,7 +104,7 @@ timer: zap: level: info format: console - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: log showLine: true encode-level: LowercaseColorLevelEncoder diff --git a/其他支持文件/文档类栏目管理/config.yaml b/其他支持文件/文档类栏目管理/config.yaml index 634d5c3..d6bba2c 100644 --- a/其他支持文件/文档类栏目管理/config.yaml +++ b/其他支持文件/文档类栏目管理/config.yaml @@ -94,7 +94,7 @@ tencent-cos: secret-id: xxxxxxxx secret-key: xxxxxxxx base-url: https://gin.vue.admin - path-prefix: github.com/flipped-aurora/gin-vue-admin/server + path-prefix: gin_server_admin timer: start: true spec: '@daily' @@ -108,7 +108,7 @@ timer: zap: level: info format: console - prefix: '[github.com/flipped-aurora/gin-vue-admin/server]' + prefix: '[gin_server_admin]' director: log showLine: true encode-level: LowercaseColorLevelEncoder