@tplc/business 0.4.7 → 0.4.9

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/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.4.9](http://gitlab888.30jia.com.cn/bhBank/zero-code-pro/compare/v0.4.8...v0.4.9) (2025-03-25)
6
+
7
+ ### [0.4.8](http://gitlab888.30jia.com.cn/bhBank/zero-code-pro/compare/v0.4.7...v0.4.8) (2025-03-25)
8
+
5
9
  ### [0.4.7](http://gitlab888.30jia.com.cn/bhBank/zero-code-pro/compare/v0.4.6...v0.4.7) (2025-03-25)
6
10
 
7
11
 
@@ -47,11 +47,15 @@
47
47
  backgroundColor: `rgba(241,241, 241, ${opacity})`,
48
48
  }"
49
49
  />
50
- <input
51
- class="text-[var(--content-color)] text-28rpx flex-1 mr-3"
52
- :placeholder="placeholder"
53
- v-model="form.keywords"
54
- />
50
+ <lcb-action-view
51
+ class="text-28rpx flex-1 mr-3"
52
+ :style="{
53
+ color: form.keywords ? 'var(--content-color)' : '#969696',
54
+ }"
55
+ v-bind="inputLink"
56
+ >
57
+ {{ form.keywords || placeholder }}
58
+ </lcb-action-view>
55
59
  <view class="justify-center flex flex-col items-center" @click="getLocation(true)">
56
60
  <wd-loading size="30rpx" v-if="locationIng" />
57
61
  <img
@@ -11,4 +11,5 @@ export interface LcbHomeSearch extends LcbBlockProps {
11
11
  value: string
12
12
  }[]
13
13
  link?: LcbActionViewProps
14
+ inputLink?: LcbActionViewProps
14
15
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tplc/business",
3
- "version": "0.4.7",
3
+ "version": "0.4.9",
4
4
  "keywords": [
5
5
  "业务组件"
6
6
  ],
@@ -10,4 +10,5 @@ export interface LcbHomeSearch extends LcbBlockProps {
10
10
  value: string
11
11
  }[]
12
12
  link?: LcbActionViewProps
13
+ inputLink?: LcbActionViewProps
13
14
  }
@@ -3,12 +3,12 @@ export declare function formatJson(str: string | object | undefined, defVal?: {}
3
3
  /** 获取上个页面Exposed */
4
4
  export declare const getExposed: () => any
5
5
  export declare const getCurrentPage: () => {
6
- pageId: number
6
+ pageId: string | number
7
7
  fullPath: string
8
8
  options: any
9
9
  route: string
10
10
  }
11
- export declare const getPreviousPageId: () => number
11
+ export declare const getPreviousPageId: () => string | number
12
12
  /** 合并url参数 url = /pages/data/index?id=1&name=2 urlParams = id=1&name=2&type=1 */
13
13
  export declare const getFinalUrl: (url: string, urlParams?: string) => string
14
14
  export declare const onPageScrollSelector: (selector: string) => void
package/utils/utils.ts CHANGED
@@ -23,6 +23,7 @@ export const getExposed = () => {
23
23
  export const getCurrentPage = () => {
24
24
  const page = getCurrentPages().pop() as {
25
25
  $page: {
26
+ id: string
26
27
  fullPath: string
27
28
  }
28
29
  route: string
@@ -30,7 +31,7 @@ export const getCurrentPage = () => {
30
31
  }
31
32
  const fullPath = decodeURIComponent(page.$page?.fullPath?.split('?')[1] || '')
32
33
  return {
33
- pageId: page.getPageId?.(),
34
+ pageId: isH5 ? page.$page.id : page.getPageId?.(),
34
35
  fullPath: page.$page?.fullPath,
35
36
  options: parse(fullPath),
36
37
  route: page.route,
@@ -41,11 +42,13 @@ export const getCurrentPage = () => {
41
42
  export const getPreviousPageId = () => {
42
43
  const pages = getCurrentPages()
43
44
  const page = pages[pages.length - 2] as {
45
+ $page: {
46
+ id: string
47
+ }
44
48
  getPageId: () => number
45
49
  }
46
- return page.getPageId?.()
50
+ return isH5 ? page?.$page?.id : page?.getPageId?.()
47
51
  }
48
-
49
52
  /** 合并url参数 url = /pages/data/index?id=1&name=2 urlParams = id=1&name=2&type=1 */
50
53
  export const getFinalUrl = (url: string, urlParams?: string) => {
51
54
  if (!urlParams) return url