htui-yllkbz 1.3.31 → 1.3.35

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.
@@ -4,32 +4,39 @@
4
4
  * @Author: hutao
5
5
  * @Date: 2021-12-30 15:47:47
6
6
  * @LastEditors: hutao
7
- * @LastEditTime: 2022-04-24 09:46:42
7
+ * @LastEditTime: 2022-07-10 14:38:04
8
8
  -->
9
9
 
10
10
  <template>
11
11
  <div>
12
12
  <template v-if="!readonly">
13
- <el-select value=""
14
- v-if="!dataTypeId"
15
- :disabled="disabled"
16
- style="width:100%"
17
- placeholder="请选择"></el-select>
18
- <HtBaseData v-else
19
- :disabled="disabled"
20
- com-style="background:#fff"
21
- :config-json="configJson"
22
- @change="getCommonData"></HtBaseData>
23
-
13
+ <el-select
14
+ value=""
15
+ v-if="!dataTypeId"
16
+ :disabled="disabled"
17
+ style="width:100%"
18
+ placeholder="请选择"
19
+ ></el-select>
20
+ <HtBaseData
21
+ v-else
22
+ :org="org"
23
+ :hide-code="hideCode"
24
+ :disabled="disabled"
25
+ com-style="background:#fff"
26
+ :config-json="configJson"
27
+ @change="getCommonData"
28
+ ></HtBaseData>
24
29
  </template>
25
30
  <div v-else>
26
- <HtShowBaseData v-if="this.value"
27
- :hide-code="hideCode"
28
- :show-all-level="showAllLevels"
29
- :base-data-id='this.value'
30
- :base-data-info='true'
31
- com-style="font-size:12px"
32
- style="font-size:12px">
31
+ <HtShowBaseData
32
+ v-if="this.value"
33
+ :hide-code="hideCode"
34
+ :show-all-level="showAllLevels"
35
+ :base-data-id="this.value"
36
+ :base-data-info="true"
37
+ com-style="font-size:12px"
38
+ style="font-size:12px"
39
+ >
33
40
  </HtShowBaseData>
34
41
  <!-- <div is='common-datas-info-id'
35
42
  com-style="font-size:12px"
@@ -38,21 +45,19 @@
38
45
  :base-data-id='this.value'
39
46
  :base-data-info='true'></div> -->
40
47
  </div>
41
-
42
48
  </div>
43
-
44
49
  </template>
45
- <script lang='ts'>
46
- import { Component, Prop, Vue, Watch } from "vue-property-decorator";
47
- import HtShowBaseData from "@/packages/HtShowBaseData";
48
- import HtBaseData from "@/packages/HtBaseData";
50
+ <script lang="ts">
51
+ import { Component, Prop, Vue, Watch } from 'vue-property-decorator';
52
+ import HtShowBaseData from '@/packages/HtShowBaseData';
53
+ import HtBaseData from '@/packages/HtBaseData';
49
54
  interface State {
50
55
  /** 数据状态 */
51
56
  loading: boolean;
52
57
  value?: string;
53
58
  }
54
59
  @Component({
55
- name: "HtSelectBaseData",
60
+ name: 'HtSelectBaseData',
56
61
  components: {
57
62
  HtShowBaseData,
58
63
  HtBaseData,
@@ -60,12 +65,14 @@ interface State {
60
65
  })
61
66
  export default class HtSelectBaseData extends Vue {
62
67
  @Prop() value!: string;
68
+ @Prop() org?: string;
63
69
  /** 是否禁用 */
64
70
  @Prop({ default: false }) disabled?: boolean;
65
71
  /* 是否只读 */
66
72
  @Prop({ default: false }) readonly?: boolean;
67
73
  /** 级联id */
68
74
  @Prop() dataTypeId!: string;
75
+ @Prop() collapseTags!: boolean;
69
76
  /** 展示时候是否隐藏value */
70
77
  @Prop() hideCode!: boolean;
71
78
  @Prop({ default: false }) clearable!: boolean;
@@ -76,7 +83,7 @@ export default class HtSelectBaseData extends Vue {
76
83
  /** 数据 */
77
84
  state: State = {
78
85
  loading: false,
79
- value: "",
86
+ value: '',
80
87
  };
81
88
  /** 生命周期 */
82
89
  created() {
@@ -101,13 +108,13 @@ export default class HtSelectBaseData extends Vue {
101
108
  data = dep[0].id;
102
109
  }
103
110
  }
104
- this.$emit("input", data);
105
- this.$emit("change", data, dep);
111
+ this.$emit('input', data);
112
+ this.$emit('change', data, dep);
106
113
  // this.$emit("input", id);
107
114
  // this.$emit("change", id, data[this.dataTypeId][0]);
108
115
  }
109
116
  /** 监听 */
110
- @Watch("value")
117
+ @Watch('value')
111
118
  onValue(val: string) {
112
119
  this.state.value = val;
113
120
  }
@@ -115,16 +122,17 @@ export default class HtSelectBaseData extends Vue {
115
122
  /** 选项列表 */
116
123
  /** 基础组件应用json */
117
124
  get configJson() {
118
- const { dataTypeId = "", value } = this;
125
+ const { dataTypeId = '', value } = this;
119
126
  const body: { [key: string]: any } = {};
120
127
  body[dataTypeId] = {
121
- name: "cece",
128
+ name: 'cece',
122
129
  show: true,
123
130
  filterable: true,
124
131
  clearable: this.clearable,
125
132
  disabled: this.disabled,
126
133
  showAllLevels: this.showAllLevels,
127
134
  multiple: this.multiple,
135
+ collapseTags: this.collapseTags,
128
136
  code: dataTypeId,
129
137
  data: {},
130
138
  checkStrictly: this.checkStrictly,
@@ -135,4 +143,4 @@ export default class HtSelectBaseData extends Vue {
135
143
  }
136
144
  }
137
145
  </script>
138
- <style lang='scss' scoped></style>
146
+ <style lang="scss" scoped></style>
@@ -4,33 +4,37 @@
4
4
  * @Author: hutao
5
5
  * @Date: 2021-12-30 14:29:14
6
6
  * @LastEditors: hutao
7
- * @LastEditTime: 2022-04-13 13:45:57
7
+ * @LastEditTime: 2022-07-10 16:49:11
8
8
  -->
9
9
  <template>
10
10
  <span v-if="readonly">
11
-
12
- <HtShowBaseData v-if="value"
13
- :department-id="JSON.stringify([value])"></HtShowBaseData>
11
+ <HtShowBaseData
12
+ v-if="value"
13
+ :org="org"
14
+ :department-id="JSON.stringify([value])"
15
+ ></HtShowBaseData>
14
16
  <span v-else> </span>
15
17
  </span>
16
- <HtBaseData v-else
17
- :disabled="disabled"
18
- com-style="background:#fff"
19
- :config-json="configJson"
20
- com-class='ht-item-common'
21
- @change="searchCommonData"></HtBaseData>
22
-
18
+ <HtBaseData
19
+ v-else
20
+ :org="org"
21
+ :disabled="disabled"
22
+ com-style="background:#fff"
23
+ :config-json="configJson"
24
+ com-class="ht-item-common"
25
+ @change="searchCommonData"
26
+ ></HtBaseData>
23
27
  </template>
24
- <script lang='ts'>
25
- import { Component, Prop, Vue } from "vue-property-decorator";
26
- import HtShowBaseData from "@/packages/HtShowBaseData";
27
- import HtBaseData from "@/packages/HtBaseData";
28
+ <script lang="ts">
29
+ import { Component, Prop, Vue } from 'vue-property-decorator';
30
+ import HtShowBaseData from '@/packages/HtShowBaseData';
31
+ import HtBaseData from '@/packages/HtBaseData';
28
32
  interface State {
29
33
  /** 数据状态 */
30
34
  loading: boolean;
31
35
  }
32
36
  @Component({
33
- name: "HtSelectOrg",
37
+ name: 'HtSelectOrg',
34
38
  components: {
35
39
  HtShowBaseData,
36
40
  HtBaseData,
@@ -40,12 +44,14 @@ export default class HtSelectOrg extends Vue {
40
44
  @Prop() value!: string;
41
45
  /** 是否禁用 */
42
46
  @Prop() disabled?: boolean;
47
+ @Prop() org?: string;
43
48
  /** 是否可以清除 */
44
49
  @Prop() clearable?: boolean;
45
50
  @Prop({ default: true }) show?: boolean;
46
51
  @Prop({ default: false }) multiple?: boolean;
47
52
  @Prop({ default: true }) showAllLevels?: boolean;
48
53
  @Prop({ default: true }) checkStrictly?: boolean;
54
+ @Prop() collapseTags!: boolean;
49
55
  /* 是否只读 */
50
56
  @Prop({ default: false }) readonly?: boolean;
51
57
  @Prop({ default: false }) panel?: boolean;
@@ -57,7 +63,7 @@ export default class HtSelectOrg extends Vue {
57
63
  /** 方法 */
58
64
  /**部门选择回调 */
59
65
  searchCommonData(res: any) {
60
- const dep = res["departmentId"];
66
+ const dep = res['departmentId'];
61
67
 
62
68
  let data = undefined;
63
69
  if (dep.length) {
@@ -71,21 +77,22 @@ export default class HtSelectOrg extends Vue {
71
77
  data = dep[0].id;
72
78
  }
73
79
  }
74
- this.$emit("input", data);
75
- this.$emit("change", data);
80
+ this.$emit('input', data);
81
+ this.$emit('change', data);
76
82
  }
77
83
  /** 监听 */
78
84
  get configJson() {
79
85
  return JSON.stringify({
80
86
  departmentId: {
81
- name: "部门树结构",
87
+ name: '部门树结构',
82
88
  show: this.show,
83
89
  disabled: this.disabled,
84
90
  showAllLevels: this.showAllLevels,
85
91
  multiple: this.multiple,
86
- code: "departmentId",
92
+ code: 'departmentId',
87
93
  data: {},
88
94
  checkStrictly: this.checkStrictly,
95
+ collapseTags: this.collapseTags,
89
96
  panel: this.panel,
90
97
  key: this.value,
91
98
  clearable: this.clearable,
@@ -95,4 +102,4 @@ export default class HtSelectOrg extends Vue {
95
102
  /** 计算属性 */
96
103
  }
97
104
  </script>
98
- <style lang='scss' scoped></style>
105
+ <style lang="scss" scoped></style>
@@ -4,33 +4,37 @@
4
4
  * @Author: hutao
5
5
  * @Date: 2021-12-30 14:29:14
6
6
  * @LastEditors: hutao
7
- * @LastEditTime: 2022-04-13 13:27:23
7
+ * @LastEditTime: 2022-07-10 15:57:06
8
8
  -->
9
9
  <template>
10
-
11
10
  <span v-if="readonly">
12
- <HtShowBaseData v-if="value"
13
- :user-id="JSON.stringify([value])"></HtShowBaseData>
11
+ <HtShowBaseData
12
+ v-if="value"
13
+ :user-id="JSON.stringify([value])"
14
+ :org="org"
15
+ ></HtShowBaseData>
14
16
  <span v-else> </span>
15
17
  </span>
16
- <HtBaseData v-else
17
- :disabled="disabled"
18
- com-style="background:#fff"
19
- :config-json="configJson"
20
- com-class='ht-item-common'
21
- @change="searchCommonData"></HtBaseData>
22
-
18
+ <HtBaseData
19
+ v-else
20
+ :org="org"
21
+ :disabled="disabled"
22
+ com-style="background:#fff"
23
+ :config-json="configJson"
24
+ com-class="ht-item-common"
25
+ @change="searchCommonData"
26
+ ></HtBaseData>
23
27
  </template>
24
- <script lang='ts'>
25
- import { Component, Prop, Vue } from "vue-property-decorator";
26
- import HtShowBaseData from "@/packages/HtShowBaseData";
27
- import HtBaseData from "@/packages/HtBaseData";
28
+ <script lang="ts">
29
+ import { Component, Prop, Vue } from 'vue-property-decorator';
30
+ import HtShowBaseData from '@/packages/HtShowBaseData';
31
+ import HtBaseData from '@/packages/HtBaseData';
28
32
  interface State {
29
33
  /** 数据状态 */
30
34
  loading: boolean;
31
35
  }
32
36
  @Component({
33
- name: "HtSelectUser",
37
+ name: 'HtSelectUser',
34
38
  components: {
35
39
  HtShowBaseData,
36
40
  HtBaseData,
@@ -38,6 +42,7 @@ interface State {
38
42
  })
39
43
  export default class HtSelectUser extends Vue {
40
44
  @Prop() value!: string;
45
+ @Prop() org!: string;
41
46
  /** 是否禁用 */
42
47
  @Prop() disabled?: boolean;
43
48
  /** 是否可以清除 */
@@ -49,6 +54,7 @@ export default class HtSelectUser extends Vue {
49
54
  /* 是否只读 */
50
55
  @Prop({ default: false }) readonly?: boolean;
51
56
  @Prop({ default: false }) panel?: boolean;
57
+ @Prop({ default: false }) collapseTags?: boolean;
52
58
  /** 数据 */
53
59
  state: State = {
54
60
  loading: false,
@@ -57,7 +63,7 @@ export default class HtSelectUser extends Vue {
57
63
  /** 方法 */
58
64
  /**部门选择回调 */
59
65
  searchCommonData(res: any) {
60
- const dep = res["departmentUser"];
66
+ const dep = res['departmentUser'];
61
67
 
62
68
  let data = undefined;
63
69
  if (dep.length) {
@@ -71,23 +77,24 @@ export default class HtSelectUser extends Vue {
71
77
  data = dep[0].id;
72
78
  }
73
79
  }
74
- this.$emit("input", data);
75
- this.$emit("change", data);
80
+ this.$emit('input', data);
81
+ this.$emit('change', data);
76
82
  }
77
83
  /** 监听 */
78
84
  get configJson() {
79
85
  return JSON.stringify({
80
86
  departmentUser: {
81
- name: "部门树结构",
87
+ name: '部门树结构',
82
88
  show: this.show,
83
89
  disabled: this.disabled,
84
90
  showAllLevels: this.showAllLevels,
85
91
  multiple: this.multiple,
86
- code: "departmentUser",
92
+ code: 'departmentUser',
87
93
  data: {},
88
94
  checkStrictly: false,
89
95
  panel: this.panel,
90
96
  key: this.value,
97
+ collapseTags: this.collapseTags,
91
98
  clearable: this.clearable,
92
99
  },
93
100
  });
@@ -95,4 +102,4 @@ export default class HtSelectUser extends Vue {
95
102
  /** 计算属性 */
96
103
  }
97
104
  </script>
98
- <style lang='scss' scoped></style>
105
+ <style lang="scss" scoped></style>