w-ui-v1 1.0.88 → 1.0.89
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/package.json +1 -1
- package/w-card/w-card.vue +2 -2
- package/w-search/w-search.vue +17 -4
- package/w-table/w-table.vue +10 -8
package/package.json
CHANGED
package/w-card/w-card.vue
CHANGED
|
@@ -252,7 +252,7 @@ const getTitleValue = (value: any, title: string) => {
|
|
|
252
252
|
}}
|
|
253
253
|
</wd-tag>
|
|
254
254
|
</view>
|
|
255
|
-
<view style="font-size: 12px;margin-top:
|
|
255
|
+
<view style="font-size: 12px;margin-top: 8px;color: #ffaa00;">
|
|
256
256
|
{{getTitleValue(visibleItems.find((item) => item.id === page.secondColumn?.id), page.secondColumn?.title)}}
|
|
257
257
|
</view>
|
|
258
258
|
</view>
|
|
@@ -349,7 +349,7 @@ const getTitleValue = (value: any, title: string) => {
|
|
|
349
349
|
|
|
350
350
|
color: #000;
|
|
351
351
|
// background-color: #F8F8F8;
|
|
352
|
-
padding: 20rpx;
|
|
352
|
+
padding:0 0 20rpx 0;
|
|
353
353
|
|
|
354
354
|
/* 添加过渡动画 */
|
|
355
355
|
.cloum {
|
package/w-search/w-search.vue
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
<!-- <view class="search-icon">
|
|
6
6
|
<wd-icon name="search" size="12px" ></wd-icon>
|
|
7
7
|
</view> -->
|
|
8
|
-
<wd-drop-menu>
|
|
9
|
-
<wd-drop-menu-item ref="dropMenu"
|
|
8
|
+
<wd-drop-menu >
|
|
9
|
+
<wd-drop-menu-item ref="dropMenu" title="更多" @opened="handleOpened">
|
|
10
10
|
<view v-for="(item, index) in props.criterias" :key="index">
|
|
11
11
|
<!-- <wSelectPicker :model-value="searchData[item.sourceId] ? searchData[item.sourceId].value : ''"
|
|
12
12
|
v-if="item.extControlType === 'relselectvalue' || item.extControlType === 'entity-select'" type="radio"
|
|
@@ -51,7 +51,15 @@
|
|
|
51
51
|
</wd-drop-menu-item>
|
|
52
52
|
</wd-drop-menu>
|
|
53
53
|
</view>
|
|
54
|
-
|
|
54
|
+
<view style="flex:1;" v-if="primaryCriteria?.extControlType==='text'">
|
|
55
|
+
<wd-search @clear="search" v-model="searchData[primaryCriteria.id]" :placeholder="`搜索${primaryCriteria.title}`">
|
|
56
|
+
<template #suffix>
|
|
57
|
+
<view @click="search" style="padding:0 8px;">
|
|
58
|
+
<wd-icon name="search" />
|
|
59
|
+
</view>
|
|
60
|
+
</template>
|
|
61
|
+
</wd-search>
|
|
62
|
+
</view>
|
|
55
63
|
</view>
|
|
56
64
|
</view>
|
|
57
65
|
</template>
|
|
@@ -73,6 +81,11 @@
|
|
|
73
81
|
criterias: {
|
|
74
82
|
type: Array,
|
|
75
83
|
default: []
|
|
84
|
+
},
|
|
85
|
+
//主搜索配置
|
|
86
|
+
primaryCriteria:{
|
|
87
|
+
type:Object,
|
|
88
|
+
default:{}
|
|
76
89
|
}
|
|
77
90
|
})
|
|
78
91
|
|
|
@@ -279,7 +292,7 @@
|
|
|
279
292
|
|
|
280
293
|
<style scoped lang="scss">
|
|
281
294
|
.search-box {
|
|
282
|
-
|
|
295
|
+
display: flex;
|
|
283
296
|
.left {
|
|
284
297
|
// position: relative;
|
|
285
298
|
|
package/w-table/w-table.vue
CHANGED
|
@@ -43,7 +43,8 @@ const dataList = ref([])
|
|
|
43
43
|
const pageData = ref<{
|
|
44
44
|
criterias: []
|
|
45
45
|
buttons: string[]
|
|
46
|
-
|
|
46
|
+
primaryCriteria:{}
|
|
47
|
+
}>({ criterias: [], buttons: [], primaryCriteria:{}})
|
|
47
48
|
onLoad((option: any) => {
|
|
48
49
|
sourceId.value = props.sourceId || option.sourceId
|
|
49
50
|
mainCode.value = props.mainCode ||option.mainCode
|
|
@@ -119,16 +120,17 @@ function add() {
|
|
|
119
120
|
<template>
|
|
120
121
|
<z-paging ref="paging" v-model="dataList" :show-loading-more-when-reload="true" @query="queryList">
|
|
121
122
|
<template #top>
|
|
122
|
-
<view
|
|
123
|
+
<view >
|
|
123
124
|
<!-- 搜索 -->
|
|
124
|
-
<wSearch :criterias="pageData.criterias" @search="search" v-if="pageData.buttons.includes('query')">
|
|
125
|
+
<wSearch :primaryCriteria="pageData.primaryCriteria" :criterias="pageData.criterias" @search="search" v-if="pageData.buttons.includes('query')">
|
|
125
126
|
</wSearch>
|
|
126
|
-
|
|
127
|
-
<slot name="buttons"></slot>
|
|
128
|
-
<!-- 添加按钮 -->
|
|
129
|
-
<wd-button v-if="pageData.buttons.includes('dtmplAdd')" type="icon" icon="add" @click="add" />
|
|
130
|
-
</view>
|
|
127
|
+
|
|
131
128
|
</view>
|
|
129
|
+
<view style="display: flex;justify-content: flex-end;">
|
|
130
|
+
<slot name="buttons"></slot>
|
|
131
|
+
<!-- 添加按钮 -->
|
|
132
|
+
<wd-button v-if="pageData.buttons.includes('dtmplAdd')" type="icon" icon="add" @click="add" />
|
|
133
|
+
</view>
|
|
132
134
|
</template>
|
|
133
135
|
<!-- 卡片 -->
|
|
134
136
|
<view class="card-list" v-if="dataList.length > 0">
|