htui-yllkbz 1.3.26 → 1.3.29
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/lib/htui.common.js +178 -29
- package/lib/htui.common.js.gz +0 -0
- package/lib/htui.css +1 -1
- package/lib/htui.umd.js +178 -29
- package/lib/htui.umd.js.gz +0 -0
- package/lib/htui.umd.min.js +3 -3
- package/lib/htui.umd.min.js.gz +0 -0
- package/package.json +1 -1
- package/src/App.vue +6 -1
- package/src/packages/HtBaseData/index.vue +1 -0
- package/src/packages/HtShowBaseType/index.ts +15 -0
- package/src/packages/HtShowBaseType/index.vue +69 -0
- package/src/packages/index.ts +4 -3
package/lib/htui.umd.min.js.gz
CHANGED
|
Binary file
|
package/package.json
CHANGED
package/src/App.vue
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @Author: hutao
|
|
5
5
|
* @Date: 2021-11-15 14:41:40
|
|
6
6
|
* @LastEditors: hutao
|
|
7
|
-
* @LastEditTime: 2022-05-
|
|
7
|
+
* @LastEditTime: 2022-05-15 16:04:55
|
|
8
8
|
-->
|
|
9
9
|
<template>
|
|
10
10
|
<div id="app">
|
|
@@ -19,6 +19,9 @@
|
|
|
19
19
|
@change="change"></HtSelectBaseData>
|
|
20
20
|
<HtSelectOrg :clearable="true"
|
|
21
21
|
@change="testuser"></HtSelectOrg>
|
|
22
|
+
-------------
|
|
23
|
+
<HtShowBaseType value="DeviceSystemType"></HtShowBaseType>
|
|
24
|
+
----------
|
|
22
25
|
<router-view></router-view>
|
|
23
26
|
</div>
|
|
24
27
|
</template>
|
|
@@ -27,11 +30,13 @@
|
|
|
27
30
|
import { Component, Vue } from "vue-property-decorator";
|
|
28
31
|
import HtSelectBaseData from "@/packages/HtSelectBaseData";
|
|
29
32
|
import HtSelectOrg from "@/packages/HtSelectUser";
|
|
33
|
+
import HtShowBaseType from "@/packages/HtShowBaseType";
|
|
30
34
|
import { mgr } from "@/plugins/oidc-client";
|
|
31
35
|
@Component({
|
|
32
36
|
components: {
|
|
33
37
|
HtSelectBaseData,
|
|
34
38
|
HtSelectOrg,
|
|
39
|
+
HtShowBaseType,
|
|
35
40
|
},
|
|
36
41
|
})
|
|
37
42
|
export default class App extends Vue {
|
|
@@ -659,6 +659,7 @@ export default class CommonDatas extends Vue {
|
|
|
659
659
|
let checkList = [];
|
|
660
660
|
if (ref && ref.getCheckedNodes() && ref.getCheckedNodes()[0] !== null) {
|
|
661
661
|
checkList = ref.getCheckedNodes();
|
|
662
|
+
this.state.selectValData[key] = [checkList[0].data];
|
|
662
663
|
} else if (
|
|
663
664
|
ref &&
|
|
664
665
|
ref.getCheckedNodes() &&
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* @Descripttion: 基础数据展示组件
|
|
3
|
+
* @version:
|
|
4
|
+
* @Author: hutao
|
|
5
|
+
* @Date: 2022-04-12 17:34:51
|
|
6
|
+
* @LastEditors: hutao
|
|
7
|
+
* @LastEditTime: 2022-05-15 14:54:08
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
import HtShowBaseType from "./index.vue";
|
|
11
|
+
(HtShowBaseType as any).install = function (Vue: any) {
|
|
12
|
+
|
|
13
|
+
Vue.component("HtShowBaseType", HtShowBaseType);
|
|
14
|
+
};
|
|
15
|
+
export default HtShowBaseType;
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
* @Descripttion:
|
|
3
|
+
* @version:
|
|
4
|
+
* @Author: hutao
|
|
5
|
+
* @Date: 2022-05-15 14:53:15
|
|
6
|
+
* @LastEditors: hutao
|
|
7
|
+
* @LastEditTime: 2022-05-15 16:06:01
|
|
8
|
+
-->
|
|
9
|
+
<template>
|
|
10
|
+
<span>{{state.value}}</span>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script lang="ts">
|
|
14
|
+
import { Vue, Prop, Component, Watch } from "vue-property-decorator";
|
|
15
|
+
import { baseConfig } from "vue-kst-auth";
|
|
16
|
+
|
|
17
|
+
interface State {
|
|
18
|
+
value: string;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
@Component({
|
|
22
|
+
name: "HtShowBaseType",
|
|
23
|
+
})
|
|
24
|
+
export default class HtShowBaseType extends Vue {
|
|
25
|
+
/** 查找不到为空时显示 */
|
|
26
|
+
@Prop() value?: string;
|
|
27
|
+
|
|
28
|
+
/** 人员 */
|
|
29
|
+
/** 数据 */
|
|
30
|
+
state: State = {
|
|
31
|
+
value: "",
|
|
32
|
+
};
|
|
33
|
+
/** 生命周期 */
|
|
34
|
+
created() {
|
|
35
|
+
//
|
|
36
|
+
}
|
|
37
|
+
/** 方法 */
|
|
38
|
+
|
|
39
|
+
@Watch("value", { immediate: true })
|
|
40
|
+
setText(val: string) {
|
|
41
|
+
this.state.value = "";
|
|
42
|
+
if (!val) {
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
if (!baseConfig.getLoginState()) {
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
48
|
+
const data = window.localStorage.getItem("commonDatas");
|
|
49
|
+
|
|
50
|
+
if (data) {
|
|
51
|
+
const dictionaryCategory =
|
|
52
|
+
JSON.parse(data)["dictionaryCategory"]["items"];
|
|
53
|
+
const item = dictionaryCategory.find((item: any) => item.code === val);
|
|
54
|
+
this.state.value = item?.name || "";
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
</script>
|
|
59
|
+
|
|
60
|
+
<style lang="scss" scoped>
|
|
61
|
+
.show-common-item {
|
|
62
|
+
display: inline-block;
|
|
63
|
+
.item {
|
|
64
|
+
+ .item {
|
|
65
|
+
padding-left: 10px;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
</style>
|
package/src/packages/index.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @Author: hutao
|
|
5
5
|
* @Date: 2021-10-21 10:08:41
|
|
6
6
|
* @LastEditors: hutao
|
|
7
|
-
* @LastEditTime: 2022-05-
|
|
7
|
+
* @LastEditTime: 2022-05-15 15:58:44
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
// 导入组件
|
|
@@ -25,12 +25,13 @@ import HtSelectUser from './HtSelectUser/index'
|
|
|
25
25
|
import HtShowBaseData from './HtShowBaseData/index'
|
|
26
26
|
import HtOrgInfo from './HtOrgInfo/index'
|
|
27
27
|
import HtBaseData from './HtBaseData/index'
|
|
28
|
+
import HtShowBaseType from './HtShowBaseType'
|
|
28
29
|
|
|
29
30
|
|
|
30
31
|
|
|
31
32
|
|
|
32
33
|
// 存储组件列表
|
|
33
|
-
const components = [HtBaseData, HtSelectTable, HtPagination, HtTable, HtExport, HtUpload, HtMd, HtCountDown, HtUploadFiles, HtSelectBaseData, HtSelectOrg, HtSelectUser, HtShowBaseData, HtOrgInfo]
|
|
34
|
+
const components = [HtBaseData, HtShowBaseType, HtSelectTable, HtPagination, HtTable, HtExport, HtUpload, HtMd, HtCountDown, HtUploadFiles, HtSelectBaseData, HtSelectOrg, HtSelectUser, HtShowBaseData, HtOrgInfo]
|
|
34
35
|
// 定义 install 方法,接收 Vue 作为参数。如果使用 use 注册插件,则所有的组件都将被注册
|
|
35
36
|
const install = function (Vue: any) {
|
|
36
37
|
// 判断是否安装
|
|
@@ -46,7 +47,7 @@ export default {
|
|
|
46
47
|
// 导出的对象必须具有 install,才能被 Vue.use() 方法安装
|
|
47
48
|
install,
|
|
48
49
|
// 以下是具体的组件列表
|
|
49
|
-
HtSelectTable, HtPagination, HtTable, HtExport, HtUpload, HtMd, HtCountDown, HtUploadFiles,
|
|
50
|
+
HtSelectTable, HtPagination, HtShowBaseType, HtTable, HtExport, HtUpload, HtMd, HtCountDown, HtUploadFiles,
|
|
50
51
|
HtSelectBaseData, HtSelectOrg, HtSelectUser, HtShowBaseData, HtOrgInfo, HtBaseData
|
|
51
52
|
}
|
|
52
53
|
|