Browse Source

完成ui组件库替代 领包广场开发

yuanmingze 4 tháng trước cách đây
mục cha
commit
5fb54e216f

+ 12 - 8
components.d.ts

@@ -8,13 +8,17 @@ export {}
 declare module 'vue' {
   export interface GlobalComponents {
     AuthInputItem: typeof import('./src/components/auth/AuthInputItem.vue')['default']
-    WdActionSheet: typeof import('wot-design-uni/components/wd-action-sheet/wd-action-sheet.vue')['default']
-    WdButton: typeof import('wot-design-uni/components/wd-button/wd-button.vue')['default']
-    WdCheckbox: typeof import('wot-design-uni/components/wd-checkbox/wd-checkbox.vue')['default']
-    WdConfigProvider: typeof import('wot-design-uni/components/wd-config-provider/wd-config-provider.vue')['default']
-    WdIcon: typeof import('wot-design-uni/components/wd-icon/wd-icon.vue')['default']
-    WdNavbar: typeof import('wot-design-uni/components/wd-navbar/wd-navbar.vue')['default']
-    WdNoticeBar: typeof import('wot-design-uni/components/wd-notice-bar/wd-notice-bar.vue')['default']
-    WdPopup: typeof import('wot-design-uni/components/wd-popup/wd-popup.vue')['default']
+    WdActionSheet: typeof import('@wot-ui/ui/components/wd-action-sheet/wd-action-sheet.vue')['default']
+    WdButton: typeof import('@wot-ui/ui/components/wd-button/wd-button.vue')['default']
+    WdCheckbox: typeof import('@wot-ui/ui/components/wd-checkbox/wd-checkbox.vue')['default']
+    WdConfigProvider: typeof import('@wot-ui/ui/components/wd-config-provider/wd-config-provider.vue')['default']
+    WdEmpty: typeof import('@wot-ui/ui/components/wd-empty/wd-empty.vue')['default']
+    WdIcon: typeof import('@wot-ui/ui/components/wd-icon/wd-icon.vue')['default']
+    WdLoading: typeof import('@wot-ui/ui/components/wd-loading/wd-loading.vue')['default']
+    WdNavbar: typeof import('@wot-ui/ui/components/wd-navbar/wd-navbar.vue')['default']
+    WdNoticeBar: typeof import('@wot-ui/ui/components/wd-notice-bar/wd-notice-bar.vue')['default']
+    WdPopup: typeof import('@wot-ui/ui/components/wd-popup/wd-popup.vue')['default']
+    WdSearch: typeof import('@wot-ui/ui/components/wd-search/wd-search.vue')['default']
+    WdTag: typeof import('@wot-ui/ui/components/wd-tag/wd-tag.vue')['default']
   }
 }

+ 2 - 2
package.json

@@ -32,6 +32,7 @@
     "@dcloudio/uni-mp-xhs": "3.0.0-4080420251103001",
     "@dcloudio/uni-quickapp-webview": "3.0.0-4080420251103001",
     "@dcloudio/uni-ui": "^1.5.11",
+    "@wot-ui/ui": "^2.0.5",
     "async-validator": "^4.2.5",
     "dayjs": "^1.11.19",
     "lodash-es": "^4.17.22",
@@ -40,8 +41,7 @@
     "pinia-plugin-persistedstate": "^4.7.1",
     "qs": "^6.14.1",
     "vue": "^3.4.21",
-    "vue-i18n": "^9.1.9",
-    "wot-design-uni": "^1.14.0"
+    "vue-i18n": "^9.1.9"
   },
   "devDependencies": {
     "@dcloudio/types": "^3.4.8",

+ 17 - 17
pnpm-lock.yaml

@@ -59,6 +59,9 @@ importers:
       '@dcloudio/uni-ui':
         specifier: ^1.5.11
         version: 1.5.11
+      '@wot-ui/ui':
+        specifier: ^2.0.5
+        version: 2.0.5(vue@3.5.26(typescript@4.9.5))
       async-validator:
         specifier: ^4.2.5
         version: 4.2.5
@@ -86,9 +89,6 @@ importers:
       vue-i18n:
         specifier: ^9.1.9
         version: 9.14.5(vue@3.5.26(typescript@4.9.5))
-      wot-design-uni:
-        specifier: ^1.14.0
-        version: 1.14.0(vue@3.5.26(typescript@4.9.5))
     devDependencies:
       '@dcloudio/types':
         specifier: ^3.4.8
@@ -1987,6 +1987,12 @@ packages:
       '@types/node':
         optional: true
 
+  '@wot-ui/ui@2.0.5':
+    resolution: {integrity: sha512-dnYMU1ma1W/uh92F3D5MgMxEhY5L+6SAOMtTK9eJve+v2SsA5HJEe4a/+UopcivZuA4qI+CbqDDjReMygOVd0Q==}
+    engines: {HBuilderX: ^3.8.7}
+    peerDependencies:
+      vue: '>=3.2.47'
+
   abab@2.0.6:
     resolution: {integrity: sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA==}
     deprecated: Use your platform's native atob() and btoa() methods instead
@@ -2895,8 +2901,8 @@ packages:
     resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==}
     engines: {node: '>= 4'}
 
-  immutable@4.3.7:
-    resolution: {integrity: sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==}
+  immutable@4.3.8:
+    resolution: {integrity: sha512-d/Ld9aLbKpNwyl0KiM2CT1WYvkitQ1TSvmRtkcV8FKStiDoA7Slzgjmb/1G2yhKM1p0XeNOieaTbFZmU1d3Xuw==}
 
   import-fresh@3.3.1:
     resolution: {integrity: sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==}
@@ -4361,12 +4367,6 @@ packages:
     resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==}
     engines: {node: '>=0.10.0'}
 
-  wot-design-uni@1.14.0:
-    resolution: {integrity: sha512-FaBXtmxxAkZNZUxR2xeKBg/Agck+SPaFFFeCvbBzAFeqM/5m2Y/v/7te7rhMJpZFkMoAgtJR1yaWR0DnjOmTnA==}
-    engines: {HBuilderX: ^3.8.7}
-    peerDependencies:
-      vue: '>=3.2.47'
-
   wrap-ansi@7.0.0:
     resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==}
     engines: {node: '>=10'}
@@ -7074,6 +7074,10 @@ snapshots:
     optionalDependencies:
       '@types/node': 25.0.3
 
+  '@wot-ui/ui@2.0.5(vue@3.5.26(typescript@4.9.5))':
+    dependencies:
+      vue: 3.5.26(typescript@4.9.5)
+
   abab@2.0.6: {}
 
   accepts@1.3.8:
@@ -8054,7 +8058,7 @@ snapshots:
 
   ignore@5.3.2: {}
 
-  immutable@4.3.7: {}
+  immutable@4.3.8: {}
 
   import-fresh@3.3.1:
     dependencies:
@@ -9184,7 +9188,7 @@ snapshots:
   sass@1.78.0:
     dependencies:
       chokidar: 3.6.0
-      immutable: 4.3.7
+      immutable: 4.3.8
       source-map-js: 1.2.1
 
   sax@1.4.4: {}
@@ -9695,10 +9699,6 @@ snapshots:
 
   word-wrap@1.2.5: {}
 
-  wot-design-uni@1.14.0(vue@3.5.26(typescript@4.9.5)):
-    dependencies:
-      vue: 3.5.26(typescript@4.9.5)
-
   wrap-ansi@7.0.0:
     dependencies:
       ansi-styles: 4.3.0

+ 17 - 0
resolvers/wot-ui-resolver.ts

@@ -0,0 +1,17 @@
+import type { ComponentResolver } from '@uni-helper/vite-plugin-uni-components'
+import { kebabCase } from '@uni-helper/vite-plugin-uni-components'
+
+export function WotResolver(): ComponentResolver {
+  return {
+    type: 'component',
+    resolve: (name: string) => {
+      if (name.match(/^Wd[A-Z]/)) {
+        const compName = kebabCase(name)
+        return {
+          name,
+          from: `@wot-ui/ui/components/${compName}/${compName}.vue`,
+        }
+      }
+    },
+  }
+}

+ 2 - 2
scripts/inject-manifest.ts

@@ -1,7 +1,7 @@
+import dotenv from 'dotenv'
 import fs from 'fs'
+import { applyEdits, modify } from 'jsonc-parser'
 import path from 'path'
-import dotenv from 'dotenv'
-import { modify, applyEdits } from 'jsonc-parser'
 
 /** 1️⃣ 只允许覆盖的模式(白名单) */
 type InjectMode = 'production_luoxin' | 'production_demo'

+ 1 - 1
src/App.ku.vue

@@ -1,5 +1,5 @@
 <script setup lang="ts">
-import { useConfigProvider } from 'wot-design-uni'
+import { useConfigProvider } from '@wot-ui/ui'
 
 import { useTheme } from '@/composables/useTheme'
 

+ 1 - 3
src/components.d.ts

@@ -6,7 +6,5 @@
 export {}
 
 declare module 'vue' {
-  export interface GlobalComponents {
-    WdButton: typeof import('wot-design-uni/components/wd-button/wd-button.vue')['default']
-  }
+  export interface GlobalComponents {}
 }

+ 1 - 0
src/pages-task/task-entry-page/index.vue

@@ -1,3 +1,4 @@
+
 <template>
   <view class="task-entry">
     <view

+ 439 - 0
src/pages-task/task-package/list.vue

@@ -0,0 +1,439 @@
+<template>
+  <view class="task-package-list">
+    <view class="task-filter-header">
+      <view class="task-filter-header__search">
+        <wd-search
+          v-model="params.keyword"
+          hide-cancel
+          placeholder-left
+          placeholder="搜索任务包名称/编号"
+          @change="onKeywordChange"
+          @clear="handleClearSearch"
+        />
+      </view>
+
+      <view class="task-list-controls">
+        <view class="task-list-controls__tabs">
+          <view
+            v-for="tab in tabs"
+            :key="tab.value"
+            class="task-list-controls__tab"
+            :class="{ 'task-list-controls__tab--active': params.activeTab === tab.value }"
+            @click="handleTabChange(tab.value)"
+          >
+            {{ tab.label }}
+            <text v-if="tab.value === TaskPackageTab.Available">({{ params.total }})</text>
+          </view>
+        </view>
+
+        <view class="task-list-controls__date" @click="openDatePicker">
+          <view class="task-list-controls__divider" />
+          <text class="task-list-controls__date-text">{{ selectedDateText }}</text>
+          <wd-icon name="arrow-down" size="28rpx" />
+        </view>
+      </view>
+    </view>
+
+    <view v-if="showEmpty" class="task-empty">
+      <wd-empty icon="no-content" tip="暂无内容" />
+    </view>
+
+    <view v-else class="task-list-content">
+      <view v-for="item in packageListArr" :key="item.id" class="task-card">
+        <view class="task-card__header">
+          <view class="task-card__title">
+            {{ item.scorePackageName }}{{ item.packageSn ? `(${item.packageSn})` : '' }}
+            <wd-tag
+              v-if="getPackageTypeTag(item.packageType1)"
+              custom-class="task-card__tag"
+              plain
+              :color="getPackageTypeTag(item.packageType1)?.color"
+              :bg-color="getPackageTypeTag(item.packageType1)?.bgColor"
+            >
+              {{ getPackageTypeTag(item.packageType1)?.label }}
+            </wd-tag>
+          </view>
+
+          <wd-button
+            v-if="params.activeTab === TaskPackageTab.Available"
+            size="small"
+            round
+            custom-class="task-card__button"
+            @click.stop="handleReceive(item)"
+          >
+            立即领取
+          </wd-button>
+
+          <view v-else class="task-card__status">
+            <view class="task-card__dot" />
+            <text>{{ getPackageStatusText(item.packageStatus) }}</text>
+          </view>
+        </view>
+
+        <view class="task-card__info">
+          <view>发包企业:{{ item.packageEntName || '-' }}</view>
+
+          <view class="task-card__meta">
+            <text>需求人数:{{ item.userGetNum }}/{{ item.userNum }}</text>
+            <text>预计积分值:{{ item.score }}分</text>
+            <text v-if="item.taskNum">任务数:{{ item.taskNum }}个</text>
+          </view>
+
+          <view>发布时间:{{ formatDate(item.createTime) }}</view>
+          <view>需求描述:{{ item.description || '无' }}</view>
+        </view>
+
+        <view v-if="item.packageStatus === '2'" class="task-card__expired">
+          <image src="/static/images/common/expired.png" mode="heightFix" />
+        </view>
+      </view>
+
+      <view class="task-load-status">
+        <text v-if="loading">加载中...</text>
+        <text v-else-if="finished">没有更多了</text>
+      </view>
+    </view>
+  </view>
+</template>
+
+<script setup lang="ts">
+import { computed, onBeforeMount, onBeforeUnmount, reactive, ref } from 'vue'
+
+import { onReachBottom } from '@dcloudio/uni-app'
+
+import { debounce } from '@/plugins/debounce'
+
+import { getUserScorePackageListApi } from '@/services/modules/task/list'
+import type {
+  getUserScorePackageListRequest,
+  TaskPackageItem,
+} from '@/services/modules/task/list/type'
+
+enum TaskPackageTab {
+  Available = '1',
+  Received = '2',
+}
+
+const tabs = [
+  { label: '可领取', value: TaskPackageTab.Available },
+  { label: '已领取', value: TaskPackageTab.Received },
+] as const
+
+const params = reactive({
+  keyword: '',
+  total: 0,
+  activeTab: TaskPackageTab.Available,
+  current: 1,
+  size: 10,
+  selectedYear: '',
+  selectedMonth: '',
+})
+
+const loading = ref(false)
+const finished = ref(false)
+const packageListArr = ref<TaskPackageItem[]>([])
+
+let requestId = 0
+
+const selectedDate = computed(() => {
+  const { selectedYear, selectedMonth } = params
+  return selectedYear && selectedMonth ? `${selectedYear}-${selectedMonth}` : ''
+})
+
+const selectedDateText = computed(() => {
+  const { selectedYear, selectedMonth } = params
+  return selectedYear && selectedMonth ? `${selectedYear}年${selectedMonth}月` : '日期'
+})
+
+const requestParams = computed<getUserScorePackageListRequest>(() => ({
+  current: params.current,
+  size: params.size,
+  selType: params.activeTab,
+  selDate: selectedDate.value,
+  packageName: params.keyword.trim(),
+}))
+
+const showEmpty = computed(() => !loading.value && packageListArr.value.length === 0)
+
+const resetList = () => {
+  params.current = 1
+  finished.value = false
+  packageListArr.value = []
+}
+
+const fetchTaskPackageList = async () => {
+  if (loading.value || finished.value) return
+
+  loading.value = true
+  const currentRequestId = ++requestId
+
+  try {
+    const res = await getUserScorePackageListApi(requestParams.value)
+    if (currentRequestId !== requestId) return
+    if (res.code !== 0) return
+
+    const records = res.data?.records ?? []
+    const total = res.data?.total ?? 0
+
+    if (params.activeTab === TaskPackageTab.Available) {
+      params.total = total
+    }
+
+    packageListArr.value = params.current === 1 ? records : packageListArr.value.concat(records)
+
+    finished.value = packageListArr.value.length >= total || records.length < params.size
+  } finally {
+    if (currentRequestId === requestId) {
+      loading.value = false
+    }
+  }
+}
+
+const refreshTaskPackageList = () => {
+  resetList()
+  fetchTaskPackageList()
+}
+
+const loadMoreTaskPackageList = () => {
+  console.log('cc')
+
+  if (loading.value || finished.value) return
+  params.current += 1
+  fetchTaskPackageList()
+}
+
+const debouncedSearch = debounce(fetchTaskPackageList, {
+  wait: 500,
+  leading: false,
+  trailing: true,
+})
+
+const onKeywordChange = () => {
+  resetList()
+  debouncedSearch()
+}
+
+const handleClearSearch = () => {
+  params.keyword = ''
+  debouncedSearch.cancel()
+  refreshTaskPackageList()
+}
+
+const handleTabChange = (value: TaskPackageTab) => {
+  if (params.activeTab === value) return
+  params.activeTab = value
+  debouncedSearch.cancel()
+  refreshTaskPackageList()
+}
+
+const openDatePicker = () => {
+  console.log('打开日期选择器')
+}
+
+const handleReceive = (item: TaskPackageItem) => {
+  console.log('立即领取:', item)
+}
+
+const getPackageTypeTag = (type: string | null) => {
+  const tagMap = {
+    '1': { label: '积分值', color: '#3fa3f1', bgColor: 'rgba(63, 163, 241, 0.1)' },
+    '6': { label: '积分值', color: '#3fa3f1', bgColor: 'rgba(63, 163, 241, 0.1)' },
+    '2': { label: '任务量', color: '#4cd964', bgColor: 'rgba(76, 217, 100, 0.1)' },
+    '3': { label: '通用', color: '#dd524d', bgColor: 'rgba(221, 82, 77, 0.1)' },
+    '4': { label: '特定', color: '#dd524d', bgColor: 'rgba(221, 82, 77, 0.1)' },
+  } as const
+
+  return type ? tagMap[type as keyof typeof tagMap] : undefined
+}
+
+const getPackageStatusText = (status: string | null) => status || '-'
+
+const formatDate = (value: string | null) => value?.slice(0, 10) || '-'
+
+onReachBottom(loadMoreTaskPackageList)
+
+onBeforeMount(fetchTaskPackageList)
+
+onBeforeUnmount(() => {
+  debouncedSearch.cancel()
+})
+</script>
+
+<style lang="scss" scoped>
+.task-package-list {
+  min-height: 100vh;
+  background: #fafafa;
+
+  .task-filter-header {
+    background: #ffffff;
+
+    .task-filter-header__search {
+      margin-bottom: 6rpx;
+    }
+
+    .task-list-controls {
+      display: flex;
+      align-items: center;
+      height: 88rpx;
+
+      .task-list-controls__tabs {
+        display: flex;
+        flex: 1;
+        height: 100%;
+      }
+
+      .task-list-controls__tab {
+        position: relative;
+        flex: 1;
+        height: 100%;
+        color: #666666;
+        font-size: 32rpx;
+        font-weight: 400;
+        line-height: 88rpx;
+        text-align: center;
+      }
+
+      .task-list-controls__tab--active {
+        color: #333333;
+        font-weight: 600;
+
+        &::after {
+          position: absolute;
+          bottom: 0;
+          left: 50%;
+          width: 78rpx;
+          height: 6rpx;
+          background: #3fa3f1;
+          border-radius: 999rpx;
+          transform: translateX(-50%);
+          content: '';
+        }
+      }
+
+      .task-list-controls__date {
+        display: flex;
+        align-items: center;
+        justify-content: center;
+        width: 220rpx;
+        height: 100%;
+        color: #333333;
+      }
+
+      .task-list-controls__divider {
+        width: 2rpx;
+        height: 42rpx;
+        margin-right: 42rpx;
+        background: #eeeeee;
+      }
+
+      .task-list-controls__date-text {
+        margin-right: 14rpx;
+        color: #333333;
+        font-size: 32rpx;
+      }
+    }
+  }
+
+  .task-list-content {
+    padding: 24rpx 32rpx;
+
+    .task-card {
+      margin-bottom: 24rpx;
+      padding: 28rpx;
+      background: #ffffff;
+      border-radius: 20rpx;
+      box-shadow: 0 6rpx 20rpx rgba(0, 0, 0, 0.04);
+
+      .task-card__header {
+        display: flex;
+        align-items: flex-start;
+        gap: 18rpx;
+      }
+
+      .task-card__title {
+        flex: 1;
+        min-width: 0;
+        color: #333333;
+        font-size: 34rpx;
+        font-weight: 600;
+        line-height: 48rpx;
+        word-break: break-all;
+      }
+
+      :deep(.task-card__tag) {
+        display: inline-flex;
+        height: 32rpx;
+        margin-left: 10rpx;
+        padding: 0 10rpx;
+        font-size: 22rpx;
+        line-height: 30rpx;
+        vertical-align: 4rpx;
+        border-radius: 6rpx;
+      }
+
+      :deep(.task-card__button) {
+        flex-shrink: 0;
+        min-width: 132rpx;
+        height: 58rpx;
+        padding: 0 18rpx;
+        color: #ffffff;
+        font-size: 28rpx;
+        background: #3fa3f1;
+        border-color: #3fa3f1;
+      }
+
+      .task-card__status {
+        display: flex;
+        flex-shrink: 0;
+        align-items: center;
+        min-height: 48rpx;
+        color: #333333;
+        font-size: 26rpx;
+      }
+
+      .task-card__dot {
+        width: 10rpx;
+        height: 10rpx;
+        margin-right: 8rpx;
+        background: #3fa3f1;
+        border-radius: 50%;
+      }
+
+      .task-card__info {
+        margin-top: 12rpx;
+        color: #999999;
+        font-size: 26rpx;
+        line-height: 42rpx;
+      }
+
+      .task-card__meta {
+        display: flex;
+        flex-wrap: wrap;
+        gap: 0 18rpx;
+      }
+
+      .task-card__expired {
+        display: flex;
+        justify-content: flex-end;
+        margin-top: 8rpx;
+
+        image {
+          width: 150rpx;
+          height: 150rpx;
+        }
+      }
+    }
+
+    .task-load-status {
+      padding: 12rpx 0 32rpx;
+      color: #999999;
+      font-size: 24rpx;
+      text-align: center;
+    }
+  }
+
+  .task-empty {
+    padding-top: 160rpx;
+  }
+}
+</style>

+ 7 - 0
src/pages.json

@@ -62,6 +62,13 @@
             "navigationBarTitleText": "任务录入",
             "navigationStyle": "default"
           }
+        },
+        {
+          "path": "task-package/list",
+          "style": {
+            "navigationBarTitleText": "领取任务包",
+            "navigationStyle": "default"
+          }
         }
       ]
     }

+ 3 - 1
src/pages/index/index.vue

@@ -110,7 +110,9 @@ const ensureCanOperate = (): boolean => {
 
 const goTask = () => {
   if (!ensureCanOperate()) return
-  console.log('去领包')
+  uni.navigateTo({
+    url: '/pages-task/task-package/list',
+  })
 }
 const taskHistory = () => {
   if (!ensureCanOperate()) return

+ 10 - 0
src/services/modules/task/list/index.ts

@@ -0,0 +1,10 @@
+import http from '../../../index'
+import type { getUserScorePackageListRequest, getUserScorePackageListResponse } from './type'
+
+// 获取当前企业配置的任务类型
+export const getUserScorePackageListApi = (params: getUserScorePackageListRequest) => {
+  return http.get<getUserScorePackageListResponse>(`/admin/api/getUserScorePackageList2`, params, {
+    loading: true,
+    loadingText: '加载中...',
+  })
+}

+ 53 - 0
src/services/modules/task/list/type.d.ts

@@ -0,0 +1,53 @@
+export interface getUserScorePackageListRequest {
+  current: number
+  size: number
+  selType: TaskPackageTab
+  selDate: string
+  packageName: string
+}
+
+export interface getUserScorePackageListResponse {
+  current: number
+  size: number
+  total: number
+  pages: number
+  records: TaskPackageItem[]
+  hitCount: boolean
+  optimizeCountSql: boolean
+  searchCount: boolean
+  orders: unknown[]
+}
+
+export interface TaskPackageItem {
+  actualTax: number | null
+  belongDate: string
+  createTime: string
+  description: string
+  enableFlag: string | null
+  enableType: string | null
+  finishScore: number | null
+  id: string
+  notifyTime: string | null
+  packageEntName: string
+  packageSn: string
+  packageStatus: string
+  packageType1: string
+  quizRelations: unknown[] | null
+  receiveTime: string | null
+  score: string
+  scorePackageName: string
+  sendPackageDeptId: string
+  settleNoteStatus: string | null
+  speedProgress: number | null
+  status: string | null
+  statusId: string | null
+  taskAddFlag: string // "1"
+  taskFinishNum: number | null
+  taskNum: number | null
+  taskNum2: number | null
+  userGetNum: number
+  userNum: number
+  userRealAmount: number | null
+  waitApprovalScore: number | null
+  waitApprovalTaskNum: number | null
+}

BIN
src/static/images/common/expired.png


+ 3 - 0
src/styles/index.scss

@@ -1 +1,4 @@
 @import './base.scss';
+@import './variables/vars-wot.scss';
+@import './variables/vars-default.scss';
+@import './variables/vars-base.scss';

+ 0 - 0
src/styles/variables/vars-defautl.scss → src/styles/variables/vars-default.scss


+ 4 - 3
src/themes/default.ts

@@ -1,11 +1,12 @@
-import type { ConfigProviderThemeVars } from 'wot-design-uni'
+import type { ConfigProviderThemeVars } from '@wot-ui/ui'
 
 export const defaultTheme = {
   theme: 'light',
   themeVars: {
-    colorTheme: '#3FA3F1',
-    buttonPrimaryBgColor: '#3fa3f1',
+    primary1: '#3FA3F1',
     buttonPrimaryColor: '#ffffff',
+    buttonPrimaryBg: '#3fa3f1',
+
   },
 } satisfies {
   theme: 'light' | 'dark'

+ 3 - 7
src/themes/luoxin.ts

@@ -1,15 +1,11 @@
-import type { ConfigProviderThemeVars } from 'wot-design-uni'
+import type { ConfigProviderThemeVars } from '@wot-ui/ui'
 
 export const luoxinTheme = {
   theme: 'light',
   themeVars: {
-    colorTheme: '#07c160',
-    buttonPrimaryBgColor: '#07c160',
+    primary1: '#07c160',
+    buttonPrimaryBg: '#07c160',
     buttonPrimaryColor: '#ffffff',
-
-    // 你可以在这里加 LUOXIN 的品牌色
-    colorSuccess: '#07c160',
-    colorWarning: '#faad14',
   },
 } satisfies {
   theme: 'light' | 'dark'

+ 0 - 4
src/uni.scss

@@ -74,7 +74,3 @@ $uni-color-subtitle: #555; // 二级标题颜色
 $uni-font-size-subtitle: 18px;
 $uni-color-paragraph: #3f536e; // 文章段落颜色
 $uni-font-size-paragraph: 15px;
-
-@import '@/styles/variables/vars-wot.scss';
-@import '@/styles/variables/vars-defautl.scss';
-@import '@/styles/variables/vars-base.scss';

+ 1 - 1
tsconfig.json

@@ -11,7 +11,7 @@
       "@dcloudio/types",
       "@uni-helper/uni-app-types",
       "@uni-helper/uni-ui-types",
-      "wot-design-uni/global",
+      "@wot-ui/ui/global",
       "miniprogram-api-typings"
     ]
   },

+ 1 - 1
vite.config.ts

@@ -4,7 +4,7 @@ import UniKuRoot from '@uni-ku/root'
 import uni from '@dcloudio/vite-plugin-uni'
 import AutoImport from 'unplugin-auto-import/vite'
 import Components from '@uni-helper/vite-plugin-uni-components'
-import { WotResolver } from '@uni-helper/vite-plugin-uni-components/resolvers'
+import { WotResolver } from './resolvers/wot-ui-resolver'
 import path from 'path'
 
 export default defineConfig(async () => {