mirror of
https://gitee.com/openharmony/applications_dlp_manager
synced 2024-11-23 09:59:57 +00:00
update
Signed-off-by: 孟立 <mengli12@huawei.com>
This commit is contained in:
parent
2c182fb4d3
commit
7caea19770
@ -9,4 +9,5 @@ userIdCipher
|
||||
telephone
|
||||
contactObjects
|
||||
isTextContent
|
||||
descriptionEn
|
||||
descriptionEn
|
||||
keywordsList
|
@ -12,8 +12,8 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import BaseResponse from "../base/BaseResponse";
|
||||
import DomainAccountInfo from "../data/DomainAccountInfo";
|
||||
import BaseResponse from '../base/BaseResponse';
|
||||
import DomainAccountInfo from '../data/DomainAccountInfo';
|
||||
|
||||
export default class DomainAccountResponse extends BaseResponse {
|
||||
|
||||
|
@ -12,8 +12,8 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { buffer } from "@kit.ArkTS";
|
||||
import { HiLog } from "./HiLog";
|
||||
import { buffer } from '@kit.ArkTS';
|
||||
import { HiLog } from './HiLog';
|
||||
|
||||
const TAG = 'CommonUtil';
|
||||
|
||||
|
@ -120,7 +120,7 @@ export default class CredConnection {
|
||||
HiLog.info(TAG, `getDomainAccountInfo sendMessageRequest is error, code: ${code}`);
|
||||
return result;
|
||||
}
|
||||
result = DomainAccountConvertor.convertToDomainAccountResp(sendResult.reply.readString());
|
||||
result = DomainAccountConvertor.convertToDomainAccountResp(sendResult.reply.readString());
|
||||
} catch (error) {
|
||||
HiLog.error(TAG, `getDomainAccountInfo result: ${error}`);
|
||||
} finally {
|
||||
|
@ -12,16 +12,16 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import DomainAccountRequest from "../bean/request/DomainAccountRequest";
|
||||
import DomainAccountResponse from "../bean/response/DomainAccountResponse";
|
||||
import CommonUtil from "../common/CommonUtil";
|
||||
import { HiLog } from "../common/HiLog";
|
||||
import DomainAccountRequest from '../bean/request/DomainAccountRequest';
|
||||
import DomainAccountResponse from '../bean/response/DomainAccountResponse';
|
||||
import CommonUtil from '../common/CommonUtil';
|
||||
import { HiLog } from '../common/HiLog';
|
||||
|
||||
const TAG = 'DomainAccountConvertor';
|
||||
|
||||
export default class DomainAccountConvertor {
|
||||
|
||||
private static readonly DOMAIN_ACCOUNT_TYPE_IDAAS =2;
|
||||
private static readonly DOMAIN_ACCOUNT_TYPE_IDAAS = 2;
|
||||
|
||||
public static convertBatchToDomainAccountReq(searchArray: string[], accountName: string, accountId: string):
|
||||
DomainAccountRequest {
|
||||
@ -29,7 +29,7 @@ export default class DomainAccountConvertor {
|
||||
result.setAccountName(CommonUtil.encodeByBase64(accountName));
|
||||
result.setAccountId(CommonUtil.encodeByBase64(accountId));
|
||||
result.setAccountType(this.DOMAIN_ACCOUNT_TYPE_IDAAS);
|
||||
result.setKeywordsList(searchArray)
|
||||
result.setKeywordsList(searchArray);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
@ -27,7 +27,7 @@ const TAG = 'AccountManager';
|
||||
export default class AccountManager {
|
||||
|
||||
public static connectAbility(context: ESObject): void {
|
||||
let connection: CredConnection | undefined = AppStorage.get<CredConnection>(AppStorageConstant.CRED_CONNECTION);
|
||||
let connection: CredConnection | undefined = AppStorage.get<CredConnection>(AppStorageConstant.CRED_CONNECTION);
|
||||
if (!connection) {
|
||||
connection = new CredConnection(context);
|
||||
}
|
||||
@ -60,7 +60,7 @@ export default class AccountManager {
|
||||
}
|
||||
let searchReq = DomainAccountConvertor.convertBatchToDomainAccountReq(
|
||||
searchArray, accountInfo.domainInfo?.accountName, accountInfo.domainInfo?.accountId);
|
||||
let connection: CredConnection | undefined = AppStorage.get<CredConnection>(AppStorageConstant.CRED_CONNECTION);
|
||||
let connection: CredConnection | undefined = AppStorage.get<CredConnection>(AppStorageConstant.CRED_CONNECTION);
|
||||
let response: DomainAccountResponse | undefined = await connection?.getDomainAccountInfo(searchReq);
|
||||
AccountManager.dealDomainAccountMapCache(response?.getData());
|
||||
return response;
|
||||
|
Loading…
Reference in New Issue
Block a user