@newview/permission-service 1.2.48 → 1.2.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/permission-service.js +59 -6
- package/dist/permission-service.umd.cjs +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -11662,6 +11662,13 @@ class UserinforInstance2 extends BaseInstance {
|
|
|
11662
11662
|
onclick: () => {
|
|
11663
11663
|
this.importCAData();
|
|
11664
11664
|
}
|
|
11665
|
+
},
|
|
11666
|
+
{
|
|
11667
|
+
name: "imgChage",
|
|
11668
|
+
text: "图签转换",
|
|
11669
|
+
onclick: () => {
|
|
11670
|
+
this.CAToImgData();
|
|
11671
|
+
}
|
|
11665
11672
|
}
|
|
11666
11673
|
],
|
|
11667
11674
|
rightToolbars: [
|
|
@@ -12270,12 +12277,32 @@ class UserinforInstance2 extends BaseInstance {
|
|
|
12270
12277
|
}));
|
|
12271
12278
|
__publicField(this, "userSignFormItems", reactive([
|
|
12272
12279
|
// { model: 'CAUserInfoKey', label: '用户KEY', type: 'Input', prop: 'CAUserInfoKey', span: 24 },
|
|
12273
|
-
{
|
|
12274
|
-
|
|
12275
|
-
|
|
12276
|
-
|
|
12277
|
-
|
|
12278
|
-
|
|
12280
|
+
{
|
|
12281
|
+
model: "CAUserSealKey",
|
|
12282
|
+
label: "印章KEY",
|
|
12283
|
+
type: "Input",
|
|
12284
|
+
prop: "CAUserSealKey",
|
|
12285
|
+
span: 24,
|
|
12286
|
+
inputProp: {
|
|
12287
|
+
append: "选择",
|
|
12288
|
+
onTextClick: () => {
|
|
12289
|
+
this.GetUserSealData(3);
|
|
12290
|
+
}
|
|
12291
|
+
}
|
|
12292
|
+
},
|
|
12293
|
+
{
|
|
12294
|
+
model: "CAUserYZKey",
|
|
12295
|
+
label: "圆章KEY",
|
|
12296
|
+
type: "Input",
|
|
12297
|
+
prop: "CAUserYZKey",
|
|
12298
|
+
span: 24,
|
|
12299
|
+
inputProp: {
|
|
12300
|
+
append: "选择",
|
|
12301
|
+
onTextClick: () => {
|
|
12302
|
+
this.GetUserSealData(2);
|
|
12303
|
+
}
|
|
12304
|
+
}
|
|
12305
|
+
}
|
|
12279
12306
|
]));
|
|
12280
12307
|
// 私有方法 | private 方法名() {}
|
|
12281
12308
|
/** 当前所选人 */
|
|
@@ -12474,6 +12501,12 @@ class UserinforInstance2 extends BaseInstance {
|
|
|
12474
12501
|
__publicField(this, "importCAData", () => {
|
|
12475
12502
|
this.importCAModal.value = true;
|
|
12476
12503
|
});
|
|
12504
|
+
__publicField(this, "CAToImgData", () => {
|
|
12505
|
+
var _a;
|
|
12506
|
+
const userDatas = (_a = this.insTreeUserGrid.value) == null ? void 0 : _a.getDatas();
|
|
12507
|
+
const users = userDatas == null ? void 0 : userDatas.filter((x) => !this.utilities.isNull(x["UserSignImgToken"]) == true);
|
|
12508
|
+
this.loadCAImgs(users, 0);
|
|
12509
|
+
});
|
|
12477
12510
|
__publicField(this, "doExcelPointImport", async (datas) => {
|
|
12478
12511
|
console.log(datas);
|
|
12479
12512
|
if (datas.length == 0) {
|
|
@@ -12897,6 +12930,26 @@ class UserinforInstance2 extends BaseInstance {
|
|
|
12897
12930
|
}
|
|
12898
12931
|
});
|
|
12899
12932
|
}
|
|
12933
|
+
async loadCAImgs(users, index2) {
|
|
12934
|
+
if (index2 == users.length) {
|
|
12935
|
+
this.message.success("转换成功!");
|
|
12936
|
+
} else {
|
|
12937
|
+
const token = users[index2].UserSignImgToken;
|
|
12938
|
+
let imgs = this.utilities.parseApiResult(await new FileApi().getFiles(token));
|
|
12939
|
+
let base64 = this.utilities.parseApiResult(await new FileApi().getBase64(token, imgs[0].Id));
|
|
12940
|
+
const apiResult = await this.userSignApi.getEntityByFilter(QueryWrapper.create().eq("UserId", users[index2].Id));
|
|
12941
|
+
const result = this.utilities.parseApiResult(apiResult);
|
|
12942
|
+
const CAUserSealImg = "data:image/png;base64," + base64;
|
|
12943
|
+
if (this.utilities.isNull(result)) {
|
|
12944
|
+
await this.userSignApi.save({ Id: 0, UserId: users[index2].Id, CAUserSealImg });
|
|
12945
|
+
} else {
|
|
12946
|
+
result.CAUserSealImg = CAUserSealImg;
|
|
12947
|
+
await this.userSignApi.save(result);
|
|
12948
|
+
}
|
|
12949
|
+
index2 += 1;
|
|
12950
|
+
this.loadCAImgs(users, index2);
|
|
12951
|
+
}
|
|
12952
|
+
}
|
|
12900
12953
|
async GetUserSealData(type2) {
|
|
12901
12954
|
this.userSealData.value = [];
|
|
12902
12955
|
this.userSealListLoading.value = true;
|