@newview/permission-service 1.2.44 → 1.2.46

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 CHANGED
@@ -1,3 +1,12 @@
1
+ ### 版本 1.2.46
2
+ 1、修改系统平台,增加路段字段
3
+
4
+
5
+
6
+ ### 版本 1.2.45
7
+ 1、判断同一平台下手机号是否唯一
8
+
9
+
1
10
  ### 版本 1.2.44
2
11
  1、更新
3
12
 
@@ -285,7 +285,8 @@ let PlatformInstance$1 = class PlatformInstance extends BaseInstance {
285
285
  LastUpdateUserId: 0,
286
286
  LastUpdateUserName: "",
287
287
  LastUpdateDate: "",
288
- DefaultPwd: ""
288
+ DefaultPwd: "",
289
+ RoadSection: ""
289
290
  }));
290
291
  __publicField(this, "platformFormItems", reactive([
291
292
  { model: "PlatformName", label: "系统名称", prop: "PlatformName", type: "Input", span: 24, rules: [{ required: true, message: "系统名称不能为空", trigger: "blur" }] },
@@ -308,7 +309,8 @@ let PlatformInstance$1 = class PlatformInstance extends BaseInstance {
308
309
  { model: "PlatformUrl", label: "系统URL", prop: "PlatformUrl", type: "Input", span: 24 },
309
310
  { model: "CABusinessKey", label: "CAKey", prop: "CABusinessKey", type: "Input", span: 24 },
310
311
  { model: "DefaultPwd", label: "用户默认密码", prop: "DefaultPwd", type: "Input", span: 24 },
311
- { model: "OrderNo", label: "排序号", prop: "OrderNo", type: "InputNumber", span: 24 }
312
+ { model: "OrderNo", label: "排序号", prop: "OrderNo", type: "InputNumber", span: 24 },
313
+ { model: "RoadSection", label: "路段", prop: "RoadSection", type: "Input", span: 24 }
312
314
  ]));
313
315
  // 响应式方法 | xxx = () => {}
314
316
  /**
@@ -475,6 +477,7 @@ let PlatformInstance$1 = class PlatformInstance extends BaseInstance {
475
477
  this.platformFormModel.PId = data.PId;
476
478
  this.platformFormModel.LastUpdateDate = this.utilities.getCurrentDate();
477
479
  this.platformFormModel.DefaultPwd = data.DefaultPwd;
480
+ this.platformFormModel.RoadSection = data.RoadSection;
478
481
  this.editPlatformModalTitle.value = `编辑 - ${data.PlatformName}`;
479
482
  const tableData = (_a = this.platformGrid.value) == null ? void 0 : _a.getDatas();
480
483
  this.platformFormItems[4].selectProp.datas = tableData.length > 0 ? tableData == null ? void 0 : tableData.map((item) => {
@@ -4535,12 +4538,14 @@ let UserinforInstance$1 = class UserinforInstance extends BaseInstance {
4535
4538
  // 响应属性 | ref、reactive、computed
4536
4539
  __publicField(this, "institutionTree", ref([]));
4537
4540
  __publicField(this, "loadingInstitutionTree", ref(false));
4541
+ __publicField(this, "insTreeIds", ref(""));
4538
4542
  // 响应式方法 | xxx = () => {}
4539
4543
  /**
4540
4544
  * 平台切换
4541
4545
  */
4542
4546
  __publicField(this, "doChangePlatform", (data) => {
4543
4547
  this.selectedPlatform = data;
4548
+ console.log(data, "11111111111111111111;;;;");
4544
4549
  this.loadInsTree();
4545
4550
  });
4546
4551
  /**
@@ -4574,6 +4579,7 @@ let UserinforInstance$1 = class UserinforInstance extends BaseInstance {
4574
4579
  __publicField(this, "doChangeInsTree", (datas) => {
4575
4580
  if (datas.length > 0) {
4576
4581
  this.selectedInsTree = datas[0];
4582
+ this.insTreeUserGrid.value.setPageIndex(1);
4577
4583
  this.loadInstitutionTreeUsers({});
4578
4584
  }
4579
4585
  });
@@ -4931,17 +4937,14 @@ let UserinforInstance$1 = class UserinforInstance extends BaseInstance {
4931
4937
  this.saveingUser.value = false;
4932
4938
  return;
4933
4939
  }
4934
- const queryWrapper2 = QueryWrapper.create();
4935
- queryWrapper2.eq("Phone", this.userFormModel.Phone).eq("IsDel", 0);
4936
- if (this.userFormModel.Id > 0) {
4937
- queryWrapper2.ne("Id", this.userFormModel.Id);
4938
- }
4939
- const apiResult2 = await this.userinforApi.isExist(queryWrapper2);
4940
- result = this.utilities.parseApiResult(apiResult2);
4941
- if (result) {
4942
- this.message.warning(`手机号 ${this.userFormModel.Phone} 已关联其他账号, 请重新输入!`);
4943
- this.saveingUser.value = false;
4944
- return;
4940
+ let res = this.utilities.parseApiResult(await this.userinforApi.getInstitutionTreeAllUsers(0, this.selectedPlatform.Id));
4941
+ if (res && res.length > 0) {
4942
+ let user = res.filter((x) => x.IsDel == 0 && x.Phone == this.userFormModel.Phone && x.Id !== this.userFormModel.Id);
4943
+ if (user.length > 0) {
4944
+ this.message.warning(`手机号 ${this.userFormModel.Phone} 已在当前平台下关联其他账号, 请重新输入!`);
4945
+ this.saveingUser.value = false;
4946
+ return;
4947
+ }
4945
4948
  }
4946
4949
  }
4947
4950
  const queryWrapper = QueryWrapper.create();
@@ -5435,6 +5438,10 @@ let UserinforInstance$1 = class UserinforInstance extends BaseInstance {
5435
5438
  this.loadingInstitutionTree.value = true;
5436
5439
  const apiResult = await this.institutionTreeApi.getInstitutionTrees(this.selectedPlatform.Id);
5437
5440
  const datas = this.utilities.parseApiResult(apiResult);
5441
+ if (datas && datas.length > 0) {
5442
+ this.insTreeIds.value = datas.map((item) => item.Id).join(",");
5443
+ this.utilities.parseApiResult(await this.userinforApi.getInstitutionTreeAllUsers(0, this.selectedPlatform.Id));
5444
+ }
5438
5445
  this.loadingInstitutionTree.value = false;
5439
5446
  const whileChildData = (pId) => {
5440
5447
  const childDatas = datas.filter((item) => item.PId == pId);
@@ -11947,17 +11954,14 @@ class UserinforInstance2 extends BaseInstance {
11947
11954
  this.saveingUser.value = false;
11948
11955
  return;
11949
11956
  }
11950
- const queryWrapper2 = QueryWrapper.create();
11951
- queryWrapper2.eq("Phone", this.userFormModel.Phone).eq("IsDel", 0);
11952
- if (this.userFormModel.Id > 0) {
11953
- queryWrapper2.ne("Id", this.userFormModel.Id);
11954
- }
11955
- const apiResult2 = await this.userinforApi.isExist(queryWrapper2);
11956
- result = this.utilities.parseApiResult(apiResult2);
11957
- if (result) {
11958
- this.message.warning(`手机号 ${this.userFormModel.Phone} 已关联其他账号, 请重新输入!`);
11959
- this.saveingUser.value = false;
11960
- return;
11957
+ let res = this.utilities.parseApiResult(await this.userinforApi.getInstitutionTreeAllUsers(0, this.selectedPlatform.Id));
11958
+ if (res && res.length > 0) {
11959
+ let user = res.filter((x) => x.IsDel == 0 && x.Phone == this.userFormModel.Phone && x.Id !== this.userFormModel.Id);
11960
+ if (user.length > 0) {
11961
+ this.message.warning(`手机号 ${this.userFormModel.Phone} 已在当前平台下关联其他账号, 请重新输入!`);
11962
+ this.saveingUser.value = false;
11963
+ return;
11964
+ }
11961
11965
  }
11962
11966
  }
11963
11967
  const queryWrapper = QueryWrapper.create();