mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-24 02:16:16 +08:00
organization
This commit is contained in:
parent
29e75a4851
commit
f98da25fda
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: admin-cms
|
- name: admin-cms
|
||||||
image: openim/admin_cms:v2.0.10k
|
image: openim/admin_cms:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10200
|
- containerPort: 10200
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: api
|
- name: api
|
||||||
image: openim/api:v2.0.10k
|
image: openim/api:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10002
|
- containerPort: 10002
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: auth
|
- name: auth
|
||||||
image: openim/auth:v2.0.10k
|
image: openim/auth:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10160
|
- containerPort: 10160
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
1
deploy_k8s/cache/deployment.yaml
vendored
1
deploy_k8s/cache/deployment.yaml
vendored
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: cache
|
- name: cache
|
||||||
image: openim/cache:v2.0.10k
|
image: openim/cache:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10240
|
- containerPort: 10240
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: cms-api
|
- name: cms-api
|
||||||
image: openim/cms_api:v2.0.10k
|
image: openim/cms_api:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10006
|
- containerPort: 10006
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: conversation
|
- name: conversation
|
||||||
image: openim/conversation:v2.0.10k
|
image: openim/conversation:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10230
|
- containerPort: 10230
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: demo
|
- name: demo
|
||||||
image: openim/demo:v2.0.10k
|
image: openim/demo:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10004
|
- containerPort: 10004
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: friend
|
- name: friend
|
||||||
image: openim/friend:v2.0.10k
|
image: openim/friend:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10120
|
- containerPort: 10120
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: group
|
- name: group
|
||||||
image: openim/group:v2.0.10k
|
image: openim/group:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10150
|
- containerPort: 10150
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: message-cms
|
- name: message-cms
|
||||||
image: openim/message_cms:v2.0.10k
|
image: openim/message_cms:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10190
|
- containerPort: 10190
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: msg
|
- name: msg
|
||||||
image: openim/msg:v2.0.10k
|
image: openim/msg:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10130
|
- containerPort: 10130
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: msg-gateway
|
- name: msg-gateway
|
||||||
image: openim/msg_gateway:v2.0.10k
|
image: openim/msg_gateway:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- name: rpc-port
|
- name: rpc-port
|
||||||
containerPort: 10140
|
containerPort: 10140
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: msg-transfer
|
- name: msg-transfer
|
||||||
image: openim/msg_transfer:v2.0.10k
|
image: openim/msg_transfer:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: config
|
- name: config
|
||||||
mountPath: /Open-IM-Server/config
|
mountPath: /Open-IM-Server/config
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: office
|
- name: office
|
||||||
image: openim/office:v2.0.10k
|
image: openim/office:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10210
|
- containerPort: 10210
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: organization
|
- name: organization
|
||||||
image: openim/organization:v2.0.10k
|
image: openim/organization:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10220
|
- containerPort: 10220
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: push
|
- name: push
|
||||||
image: openim/push:v2.0.10k
|
image: openim/push:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10170
|
- containerPort: 10170
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -16,6 +16,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: sdk-server
|
- name: sdk-server
|
||||||
image: openim/sdk_server:v2.0.10k
|
image: openim/sdk_server:v2.0.10k
|
||||||
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 10003
|
- containerPort: 10003
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
@ -161,6 +161,7 @@ func onboardingProcessNotification(operationID, userID, groupID string) {
|
|||||||
}()
|
}()
|
||||||
var tips commonPb.TipsComm
|
var tips commonPb.TipsComm
|
||||||
tips.DefaultTips = config.Config.Notification.JoinDepartmentNotification.DefaultTips.Tips
|
tips.DefaultTips = config.Config.Notification.JoinDepartmentNotification.DefaultTips.Tips
|
||||||
|
tips.JsonDetail = ""
|
||||||
content, err := proto.Marshal(&tips)
|
content, err := proto.Marshal(&tips)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.NewError(operationID, utils.GetSelfFuncName(), err.Error(), "proto marshal failed")
|
log.NewError(operationID, utils.GetSelfFuncName(), err.Error(), "proto marshal failed")
|
||||||
|
@ -154,7 +154,6 @@ func (s *organizationServer) UpdateDepartment(ctx context.Context, req *rpc.Upda
|
|||||||
|
|
||||||
department := db.Department{}
|
department := db.Department{}
|
||||||
utils.CopyStructFields(&department, req.DepartmentInfo)
|
utils.CopyStructFields(&department, req.DepartmentInfo)
|
||||||
|
|
||||||
log.Debug(req.OperationID, "dst ", department, "src ", req.DepartmentInfo)
|
log.Debug(req.OperationID, "dst ", department, "src ", req.DepartmentInfo)
|
||||||
if err := imdb.UpdateDepartment(&department, nil); err != nil {
|
if err := imdb.UpdateDepartment(&department, nil); err != nil {
|
||||||
errMsg := req.OperationID + " " + "UpdateDepartment failed " + err.Error()
|
errMsg := req.OperationID + " " + "UpdateDepartment failed " + err.Error()
|
||||||
@ -343,6 +342,7 @@ func (s *organizationServer) GetDepartmentParentIDList(_ context.Context, req *r
|
|||||||
resp = &rpc.GetDepartmentParentIDListResp{}
|
resp = &rpc.GetDepartmentParentIDListResp{}
|
||||||
resp.ParentIDList, err = imdb.GetDepartmentParentIDList(req.DepartmentID)
|
resp.ParentIDList, err = imdb.GetDepartmentParentIDList(req.DepartmentID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
log.NewError(req.OperationID, utils.GetSelfFuncName(), "GetDepartmentParentIDList failed", err.Error())
|
||||||
resp.ErrMsg = constant.ErrDB.ErrMsg + ": " + err.Error()
|
resp.ErrMsg = constant.ErrDB.ErrMsg + ": " + err.Error()
|
||||||
resp.ErrCode = constant.ErrDB.ErrCode
|
resp.ErrCode = constant.ErrDB.ErrCode
|
||||||
return resp, nil
|
return resp, nil
|
||||||
|
@ -249,10 +249,11 @@ func GetDepartmentRelatedGroupIDList(departmentIDList []string) ([]string, error
|
|||||||
|
|
||||||
func getDepartmentParent(departmentID string, dbConn *gorm.DB) (*db.Department, error) {
|
func getDepartmentParent(departmentID string, dbConn *gorm.DB) (*db.Department, error) {
|
||||||
var department db.Department
|
var department db.Department
|
||||||
var parentID string
|
//var parentID string
|
||||||
dbConn.LogMode(true)
|
dbConn.LogMode(true)
|
||||||
// select * from departments where department_id = (select parent_id from departments where department_id= zx234fd);
|
// select * from departments where department_id = (select parent_id from departments where department_id= zx234fd);
|
||||||
err := dbConn.Table("departments").Where("department_id=?", dbConn.Table("departments").Where("department_id=?", departmentID).Pluck("parent_id", parentID)).Find(&department).Error
|
//dbConn.Table("departments").Where("department_id=?", departmentID).Pluck("parent_id", parentID).Error
|
||||||
|
err := dbConn.Table("departments").Where("department_id=?").Find(&department).Error
|
||||||
return &department, err
|
return &department, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user