Documentation ¶
Index ¶
- func CreateInstAssociation(objAddr string, req *restful.Request, instAsst []*metadata.InstAsst) error
- func DeleteInstAssociation(objAddr string, req *restful.Request, instID int, ...) error
- func ExtractDataFromAssociationField(instID int64, input map[string]interface{}, asstDes []objapi.ObjAsstDes) []*metadata.InstAsst
- func GetUserFromHeader(req *restful.Request) string
- func IsSuccess(rst []byte) (*api.BKAPIRsp, bool)
- func SearchInstAssociation(objAdd string, cond map[string]interface{}, req *restful.Request) (string, error)
- func UpdateInstAssociation(objAddr string, req *restful.Request, instID int, ownerID, objID string, ...) error
- type AsstObjectInst
- func (a *AsstObjectInst) GetIDsByExcelStr(objID, key string) (int64, error)
- func (a *AsstObjectInst) GetObjAsstObjectPrimaryKey() error
- func (a *AsstObjectInst) InitInstFromData(infos map[int]map[string]interface{}) (map[int]error, error)
- func (a *AsstObjectInst) SetMapFields(objID string) error
- func (a *AsstObjectInst) SetObjAsstPropertyVal(inst map[string]interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateInstAssociation ¶
func DeleteInstAssociation ¶
func ExtractDataFromAssociationField ¶
func ExtractDataFromAssociationField(instID int64, input map[string]interface{}, asstDes []objapi.ObjAsstDes) []*metadata.InstAsst
ExtractDataFromAssociationField get asst data
func GetUserFromHeader ¶
Types ¶
type AsstObjectInst ¶
type AsstObjectInst struct {
// contains filtered or unexported fields
}
AsstObjectInst instances assocate object fields value
func NewAsstObjectInst ¶
func NewAsstObjectInst(req *restful.Request, ownerID, objAddr string, fields map[string]*sourceAPI.ObjAttDes, defLang language.DefaultCCLanguageIf) *AsstObjectInst
NewAsstObjectInst get Asst object instnace struct, NewAsstObjectInst use handle multiple instance assocate object value
func (*AsstObjectInst) GetIDsByExcelStr ¶
func (a *AsstObjectInst) GetIDsByExcelStr(objID, key string) (int64, error)
GetIDsByExcelStr Get a string of data based on multiple primary key values (multiple primary key values are sorted by field name, separated by ##)
func (*AsstObjectInst) GetObjAsstObjectPrimaryKey ¶
func (a *AsstObjectInst) GetObjAsstObjectPrimaryKey() error
GetObjAsstObjectPrimaryKey get instance assocate object primary property fields
func (*AsstObjectInst) InitInstFromData ¶
func (a *AsstObjectInst) InitInstFromData(infos map[int]map[string]interface{}) (map[int]error, error)
InitInstFromData get assocate object instance data, return map[row]error, error
func (*AsstObjectInst) SetMapFields ¶
func (a *AsstObjectInst) SetMapFields(objID string) error
SetMapFields set import object property fields
func (*AsstObjectInst) SetObjAsstPropertyVal ¶
func (a *AsstObjectInst) SetObjAsstPropertyVal(inst map[string]interface{}) error
SetObjAsstPropertyVal set instance assocate object value to property fields