Browse Source

任务列表

master
parent
commit
d7651fafc1
  1. 7
      App.vue
  2. 15
      api/system/dict.js
  3. 5
      config.js
  4. 10
      pages.json
  5. 183
      pages/enterprise.vue
  6. 2
      pages/login.vue
  7. 9
      pages/owner.vue
  8. 287
      pages/task.vue
  9. BIN
      static/favicon.png
  10. 2
      sub/chat/index.vue
  11. 107
      sub/enterprise/detail.vue
  12. 10
      sub/enterprise/edit.vue
  13. 16
      sub/owner/invite.vue
  14. 3
      uni.scss
  15. 7
      uni_modules/s-components/s-header/index.vue
  16. 2
      uni_modules/s-components/s-tabber/index.vue
  17. 1
      utils/dict.js
  18. 63
      wxcomponents/vant/dropdown-menu/index.wxss

7
App.vue

@ -1,7 +1,7 @@
<script> <script>
import config from './config' import config from './config'
import store from '@/store' import store from '@/store'
import { getAccessToken, removeToken } from '@/utils/auth' import { getAccessToken } from '@/utils/auth'
export default { export default {
onLaunch: function () { onLaunch: function () {
@ -20,11 +20,14 @@ export default {
this.checkLogin() this.checkLogin()
}, },
initConfig() { initConfig() {
// removeToken()
this.globalData.config = config this.globalData.config = config
}, },
checkLogin() { checkLogin() {
if (!getAccessToken()) {
this.$tab.reLaunch('/pages/login') this.$tab.reLaunch('/pages/login')
} else {
this.$store.dispatch('GetInfo')
}
} }
} }
} }

15
api/system/dict.js

@ -20,3 +20,18 @@ export function getDeptTree() {
method: 'GET' method: 'GET'
}) })
} }
/**
* 获取标签列表
* @param {array} params
*/
export function getTagData(params) {
return request({
url: `/system/tag-library/list`,
method: 'GET',
params: {
codeList: params
}
})
}

5
config.js

@ -1,7 +1,7 @@
// 应用全局配置 // 应用全局配置
module.exports = { module.exports = {
// baseUrl: 'http://api-dashboard.yudao.iocoder.cn', // baseUrl: 'http://api-dashboard.yudao.iocoder.cn',
baseUrl: 'http://188.188.5.98:48080', baseUrl: 'http://188.188.3.232:48080',
baseApi: '/admin-api', baseApi: '/admin-api',
// 应用信息 // 应用信息
appInfo: { appInfo: {
@ -14,7 +14,6 @@ module.exports = {
// 官方网站 // 官方网站
site_url: "", site_url: "",
// 政策协议 // 政策协议
agreements: [ agreements: []
]
} }
} }

10
pages.json

@ -1,5 +1,4 @@
{ {
"pages": [{ "pages": [{
"path": "pages/index", "path": "pages/index",
"style": { "style": {
@ -31,7 +30,12 @@
{ {
"path": "pages/task", "path": "pages/task",
"style": { "style": {
"navigationBarTitleText": "任务" "navigationBarTitleText": "任务",
"usingComponents": {
"van-dropdown-menu": "/wxcomponents/vant/dropdown-menu/index",
"van-dropdown-item": "/wxcomponents/vant/dropdown-item/index",
"van-circle": "/wxcomponents/vant/circle/index"
}
} }
}, },
{ {
@ -62,6 +66,8 @@
"path": "enterprise/detail" "path": "enterprise/detail"
}, { }, {
"path": "chat/index" "path": "chat/index"
}, {
"path": "task/detail"
}] }]
}], }],
"tabBar": { "tabBar": {

183
pages/enterprise.vue

@ -7,50 +7,100 @@
@sreach="queryEnterprise" @sreach="queryEnterprise"
@clear="resetQuery('enterpriseName')" @clear="resetQuery('enterpriseName')"
/> />
<van-dropdown-menu safe-area-tab-bar> <van-dropdown-menu safe-area-tab-bar active-color="#17C653">
<van-dropdown-item <van-dropdown-item
:value="queryParams.region" :value="queryParams.qy"
:options="getDropdownOption('enterprises_area')" :options="getDropdownOption('qy')"
@change="queryEnterprise" @change="
v => {
querySelect(v, 'qy')
}
"
/>
<van-dropdown-item
:value="queryParams.hy"
:options="getDropdownOption('hy')"
@change="
v => {
querySelect(v, 'hy')
}
"
/>
<van-dropdown-item
:value="queryParams.st"
:options="getDropdownOption('st')"
@change="
v => {
querySelect(v, 'st')
}
"
/>
<van-dropdown-item
:value="queryParams.wr"
:options="getDropdownOption('wr')"
@change="
v => {
querySelect(v, 'wr')
}
"
/> />
<van-dropdown-item :value="queryParams.dept" :options="getDropdownOption('dept')" @change="queryEnterprise" />
</van-dropdown-menu> </van-dropdown-menu>
<u-list @scrolltolower="loadMore" class="list" height="67vh"> <scroll-view
<u-list-item v-for="enterprise in list" :key="enterprise.id"> scroll-y="true"
<view class="wd-flex wd-items-center enterprise" @click="goDetail(enterprise.id)"> :refresher-enabled="true"
<u-avatar :src="enterprise.files[0]" shape="square" size="64"></u-avatar> @refresherrefresh="refresherrefresh"
:refresher-triggered="refresherTriggered"
@refresherpulling="refresherpulling"
@scrolltolower="loadMore"
class="list"
>
<view
v-for="enterprise in list"
:key="enterprise.id"
class="wd-flex wd-items-center enterprise"
@click="goDetail(enterprise.id)"
>
<u-avatar :src="enterprise.files[0].url" shape="square" size="64"></u-avatar>
<view class="wd-flex wd-flex-col" style="gap: 4px"> <view class="wd-flex wd-flex-col" style="gap: 4px">
<text class="wd-font-800">{{ enterprise.enterprisesName }}</text> <text class="wd-font-800 wd-text-15">{{ enterprise.enterprisesName }}</text>
<text class="address">{{ enterprise.address }}</text> <text class="address wd-text-12">{{ enterprise.address }}</text>
<view class="tagList">
<view class="tag" v-for="(tag, index) in enterprise.tagList" :key="index">
{{ tag }}
</view>
</view>
</view> </view>
<view <view
class="audit" class="audit"
v-if="enterprise.audit != 2" v-if="enterprise.audit != 2"
:style="{ color: enterprise.audit == 1 ? '#EAB308' : '#ea000c' }" :style="{ color: enterprise.audit == 1 ? '#F6B100' : '#ea000c', backgroundColor: '#FFF8DD' }"
> >
{{ $dict.echoDicValue(dictMap.user_audit_type, enterprise.audit) }} {{ $dict.echoDicValue(dictMap.user_audit_type, enterprise.audit) }}
</view> </view>
</view> </view>
</u-list-item> <u-loadmore :status="load" marginTop="20" />
<u-loadmore :status="load" /> </scroll-view>
</u-list>
</view> </view>
</cs-page> </cs-page>
</template> </template>
<script> <script>
import { getEnterPriseList } from '@/api/enterprise/index.js' import { getEnterPriseList } from '@/api/enterprise/index.js'
import { getDictBatchByType, getDeptTree } from '@/api/system/dict.js' import { getDictBatchByType, getDeptTree, getTagData } from '@/api/system/dict.js'
export default { export default {
data() { data() {
return { return {
queryParams: { queryParams: {
pageSize: 10, pageSize: 10,
pageNo: 1, pageNo: 1,
region: '', qy: '',
dept: '', hy: '',
enterprisesName: '' st: '',
wr: '',
enterprisesName: '',
tagList: ''
}, },
refresherTriggered: false,
list: [], list: [],
load: 'loadmore', load: 'loadmore',
dictMap: {} dictMap: {}
@ -79,29 +129,29 @@ export default {
uni.hideToast() uni.hideToast()
}, },
async getDict() { async getDict() {
const dict = await getDictBatchByType({ type: ['enterprises_area', 'user_audit_type'].join(',') }) const tags = await getTagData(['qy', ' hy', 'st', 'wr'].join(','))
const dept = await getDeptTree() const dict = await getDictBatchByType({ type: ['user_audit_type'].join(',') })
this.dictMap = { let tagMap = {}
...dict.data, tags.data.forEach(t => {
dept: dept.data.map(i => { tagMap[t.tagCode] = t.children
return {
...i,
label: i.name,
value: i.id
}
}) })
this.dictMap = {
...tagMap,
...dict.data
} }
}, },
getDropdownOption(key) { getDropdownOption(key) {
if (!this.dictMap[key]) return [] if (!this.dictMap[key]) return []
const keyMap = { const keyMap = {
enterprises_area: '全部区域', qy: '区域',
dept: '全部部门' hy: '行业',
st: '生态',
wr: '污染'
} }
const data = this.dictMap[key].map(d => { const data = this.dictMap[key].map(d => {
return { return {
value: d.value, value: d.id,
text: d.label text: d.tagName
} }
}) })
data.push({ data.push({
@ -110,10 +160,17 @@ export default {
}) })
return data return data
}, },
querySelect(v, key) {
this.queryParams[key] = v.detail
this.queryEnterprise()
},
queryEnterprise() { queryEnterprise() {
this.queryParams.pageNo = 1 this.queryParams.pageNo = 1
this.load = 'loadmore' this.load = 'loadmore'
this.list = [] this.list = []
this.queryParams.tagList = [this.queryParams.qy, this.queryParams.hy, this.queryParams.st, this.queryParams.wr]
.filter(i => i != '')
.join()
this.getList() this.getList()
}, },
loadMore() { loadMore() {
@ -127,9 +184,30 @@ export default {
this.queryParams.pageNo++ this.queryParams.pageNo++
this.getList() this.getList()
}, },
resetQuery(key) { refresherpulling() {
this.queryParams[key] = '' const that = this
this.queryEnterprise() if (!this.refresherTriggered) {
this.refresherTriggered = true
setTimeout(() => {
that.refresherTriggered = false
}, 1000)
}
},
refresherrefresh() {
this.resetQuery()
},
async resetQuery() {
this.queryParams = {
pageSize: 10,
pageNo: 1,
qy: '',
hy: '',
st: '',
wr: '',
enterprisesName: '',
tagList: ''
}
await this.queryEnterprise()
}, },
goDetail(id) { goDetail(id) {
uni.navigateTo({ uni.navigateTo({
@ -145,6 +223,10 @@ export default {
height: 100%; height: 100%;
overflow: hidden; overflow: hidden;
} }
.list {
height: 67vh;
padding: 12px;
}
.enterprise { .enterprise {
padding: 12px; padding: 12px;
background-color: #fff; background-color: #fff;
@ -152,19 +234,42 @@ export default {
gap: 12px; gap: 12px;
margin-top: 12px; margin-top: 12px;
position: relative; position: relative;
overflow: hidden;
font-size: 12px;
.address { .address {
color: $uni-text-color-grey; color: $uni-text-color-grey;
} }
.tagList {
margin-top: 8px;
display: flex;
gap: 4px;
color: $uni-text-color-grey;
display: flex;
.tag {
font-size: 12px;
display: flex;
padding: 2px 6px;
justify-content: center;
align-items: center;
border-radius: 2px;
background: #f9f9f9;
}
}
.audit { .audit {
position: absolute; position: absolute;
right: 1%; right: -19px;
top: 16%; top: 6px;
transform: rotateZ(39deg); transform: rotateZ(45deg);
transform-origin: 50% 50%; transform-origin: 50% 50%;
padding: 4px 20px;
font-size: 12px;
text-align: center;
} }
} }
::v-deep .van-dropdown-menu { ::v-deep .van-dropdown-menu {
box-shadow: none; box-shadow: none;
height: 35px;
font-size: 13px;
} }
::v-deep .u-list { ::v-deep .u-list {

2
pages/login.vue

@ -36,7 +36,6 @@ export default {
state: 'default', state: 'default',
userType: this.getUserType() userType: this.getUserType()
} }
console.log('Login', data)
// //
this.$store.dispatch('Login', data).then(() => { this.$store.dispatch('Login', data).then(() => {
this.loginSuccess() this.loginSuccess()
@ -53,7 +52,6 @@ export default {
}, },
loginSuccess() { loginSuccess() {
this.$store.dispatch('GetInfo').then(res => { this.$store.dispatch('GetInfo').then(res => {
console.log('loginSuccess', res.data)
this.handlerNavigateTo(res.data.user) this.handlerNavigateTo(res.data.user)
}) })
}, },

9
pages/owner.vue

@ -3,8 +3,8 @@
<scroll-view class="owner-container" scroll-y> <scroll-view class="owner-container" scroll-y>
<view class="section wd-flex wd-flex-row wd-justify-between wd-items-center" @tap="edit"> <view class="section wd-flex wd-flex-row wd-justify-between wd-items-center" @tap="edit">
<view class="wd-flex wd-flex-col" style="gap: 4px"> <view class="wd-flex wd-flex-col" style="gap: 4px">
<view class="wd-flex wd-flex-row" style="gap: 8px"> <view class="wd-flex wd-flex-row" style="gap: 8px; align-items: center">
<text class="wd-font-800">{{ user.realName }}</text> <text class="wd-font-800 wd-text-20">{{ user.realName }}</text>
<u-tag :text="user.dept.name" shape="circle" bgColor="#000" borderColor="#000" size="mini"></u-tag> <u-tag :text="user.dept.name" shape="circle" bgColor="#000" borderColor="#000" size="mini"></u-tag>
</view> </view>
<view class="moblie">{{ user.mobile }}</view> <view class="moblie">{{ user.mobile }}</view>
@ -46,7 +46,7 @@
</view> </view>
<view class="section wd-flex wd-flex-row wd-justify-between" @click="invite"> <view class="section wd-flex wd-flex-row wd-justify-between" @click="invite">
<view class="wd-flex wd-flex-row" style="gap: 8px"> <view class="wd-flex wd-flex-row" style="gap: 8px">
<u--image src="/static/images/owner/phone.png" width="20px" height="20px" mode="aspectFit"></u--image> <u--image src="/static/images/owner/list.png" width="20px" height="20px" mode="aspectFit"></u--image>
<text class="wd-font-800">企业入驻</text> <text class="wd-font-800">企业入驻</text>
</view> </view>
<view class="wd-flex wd-flex-row wd-items-center" style="gap: 8px"> <view class="wd-flex wd-flex-row wd-items-center" style="gap: 8px">
@ -93,7 +93,8 @@ export default {
}, },
invite() { invite() {
uni.navigateTo({ uni.navigateTo({
url: '/sub/owner/invite' // url: '/sub/owner/invite'
url: '/sub/enterprise/edit'
}) })
} }
} }

287
pages/task.vue

@ -1,13 +1,294 @@
<template> <template>
<cs-page :selected="1" isTab></cs-page> <cs-page :selected="1" title="执法任务" isTab>
<view class="page-container">
<van-dropdown-menu safe-area-tab-bar active-color="#17C653">
<van-dropdown-item
:value="queryParams.dept"
:options="getDropdownOption('dept')"
@change="
v => {
querySelect(v, 'dept')
}
"
/>
<van-dropdown-item
:value="queryParams.hy"
:options="getDropdownOption('hy')"
@change="
v => {
querySelect(v, 'hy')
}
"
/>
<van-dropdown-item
:value="queryParams.st"
:options="getDropdownOption('st')"
@change="
v => {
querySelect(v, 'st')
}
"
/>
<van-dropdown-item
:value="queryParams.wr"
:options="getDropdownOption('wr')"
@change="
v => {
querySelect(v, 'wr')
}
"
/>
</van-dropdown-menu>
<scroll-view
scroll-y="true"
:refresher-enabled="true"
@refresherrefresh="refresherrefresh"
:refresher-triggered="refresherTriggered"
@refresherpulling="refresherpulling"
@scrolltolower="loadMore"
class="list"
>
<view
v-for="enterprise in list"
:key="enterprise.id"
class="wd-flex wd-items-center enterprise"
@click="goDetail(enterprise.id)"
>
<van-circle :value="Math.random() * 100" size="56" color="#17c653" layer-color="#F1F1F4">
<template>
<u-count-to :startVal="0" :endVal="Math.random() * 100" fontSize="16" bold duration="1000"></u-count-to>
%
</template>
</van-circle>
<view class="wd-flex wd-flex-col" style="gap: 4px">
<text class="wd-font-800 wd-text-15">{{ enterprise.enterprisesName }}</text>
<text class="address wd-text-12">{{ enterprise.address }}</text>
<view class="tagList">
<view class="tag" v-for="(tag, index) in enterprise.tagList" :key="index">
{{ tag }}
</view>
</view>
</view>
<view
class="audit"
v-if="enterprise.audit != 2"
:style="{ color: enterprise.audit == 1 ? '#F6B100' : '#ea000c', backgroundColor: '#FFF8DD' }"
>
{{ $dict.echoDicValue(dictMap.user_audit_type, enterprise.audit) }}
</view>
</view>
<u-loadmore :status="load" marginTop="20" />
</scroll-view>
</view>
</cs-page>
</template> </template>
<script> <script>
import { getEnterPriseList } from '@/api/enterprise/index.js'
import { getDictBatchByType, getDeptTree, getTagData } from '@/api/system/dict.js'
export default { export default {
data() { data() {
return {} return {
queryParams: {
pageSize: 10,
pageNo: 1,
qy: '',
hy: '',
st: '',
wr: '',
dept: '',
tagList: ''
},
refresherTriggered: false,
list: [],
load: 'loadmore',
dictMap: {}
}
},
async onLoad() {
await this.getDict()
},
onShow() {
this.queryEnterprise()
},
methods: {
async getList() {
uni.showToast({
title: '加载中',
mask: true,
icon: 'loading'
})
this.load = 'loading'
const res = await getEnterPriseList(this.queryParams)
this.list.push(...res.data.list)
this.load = 'loadmore'
if (this.list.length == res.data.total) {
this.load = 'nomore'
}
uni.hideToast()
},
async getDict() {
const tags = await getTagData(['qy', ' hy', 'st', 'wr'].join(','))
const dict = await getDictBatchByType({ type: ['user_audit_type'].join(',') })
const dept = await getDeptTree()
let tagMap = {}
tags.data.forEach(t => {
tagMap[t.tagCode] = t.children
})
this.dictMap = {
...tagMap,
...dict.data,
dept: dept.data.map(i => {
return {
...i,
text: i.name,
value: i.id
}
})
}
},
getDropdownOption(key) {
if (!this.dictMap[key]) return []
const keyMap = {
qy: '区域',
hy: '行业',
st: '生态',
wr: '污染',
dept: '全部部门'
}
if (key == 'dept') {
return [...this.dictMap[key], { value: '', text: keyMap[key] }]
} else {
return [
...this.dictMap[key].map(d => {
return {
value: d.id,
text: d.tagName
}
}),
{ value: '', text: keyMap[key] }
]
}
},
querySelect(v, key) {
this.queryParams[key] = v.detail
this.queryEnterprise()
},
queryEnterprise() {
this.queryParams.pageNo = 1
this.load = 'loadmore'
this.list = []
this.queryParams.tagList = [this.queryParams.qy, this.queryParams.hy, this.queryParams.st, this.queryParams.wr]
.filter(i => i != '')
.join()
this.getList()
},
loadMore() {
if (this.load == 'nomore') {
uni.showToast({
title: '没有更多了',
icon: 'none'
})
return
}
this.queryParams.pageNo++
this.getList()
},
refresherpulling() {
const that = this
if (!this.refresherTriggered) {
this.refresherTriggered = true
setTimeout(() => {
that.refresherTriggered = false
}, 1000)
}
},
refresherrefresh() {
this.resetQuery()
},
async resetQuery() {
this.queryParams = {
pageSize: 10,
pageNo: 1,
qy: '',
hy: '',
st: '',
wr: '',
dept: '',
tagList: ''
}
await this.queryEnterprise()
},
goDetail(id) {
uni.navigateTo({
url: `/sub/task/detail?id=${id}`
})
}
} }
} }
</script> </script>
<style lang="scss"></style> <style lang="scss" scoped>
.page-container {
height: 100%;
overflow: hidden;
}
.list {
height: 75vh;
padding: 12px;
}
.enterprise {
padding: 12px;
background-color: #fff;
border-radius: $cs-border-radius;
gap: 12px;
margin-top: 12px;
position: relative;
overflow: hidden;
font-size: 12px;
.address {
color: $uni-text-color-grey;
}
.tagList {
margin-top: 8px;
display: flex;
gap: 4px;
color: $uni-text-color-grey;
display: flex;
.tag {
font-size: 12px;
display: flex;
padding: 2px 6px;
justify-content: center;
align-items: center;
border-radius: 2px;
background: #f9f9f9;
}
}
.audit {
position: absolute;
right: -19px;
top: 6px;
transform: rotateZ(45deg);
transform-origin: 50% 50%;
padding: 4px 20px;
font-size: 12px;
text-align: center;
}
}
::v-deep .van-dropdown-menu {
box-shadow: none;
height: 35px;
font-size: 13px;
}
::v-deep .u-list {
padding: 12px;
}
::v-deep .u-count-num {
font-size: 16px;
font-family: 'WeChat Sans Std';
font-weight: 800;
}
</style>

BIN
static/favicon.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 254 KiB

2
sub/chat/index.vue

@ -1,6 +1,6 @@
<template> <template>
<view class="chat-container"> <view class="chat-container">
<web-view :webview-styles="webviewStyles" src="http://192.168.2.5:28180/ui/chat/aa39d6777becd0e1"></web-view> <web-view :webview-styles="webviewStyles" src="https://mb.jzce.com/ui/chat/313cf9e35628923a"></web-view>
</view> </view>
</template> </template>

107
sub/enterprise/detail.vue

@ -11,47 +11,58 @@
<view class="detail-container"> <view class="detail-container">
<view class="box detail"> <view class="box detail">
<view> <view>
<text class="wd-font-800">{{ detail.enterprisesName }}</text> <text class="wd-font-800 wd-text-16" style="margin-bottom: 4px">{{ detail.enterprisesName }}</text>
<view class="address">
<u-icon name="map" size="14" color="#17C653"></u-icon>
{{ detail.address }}
</view> </view>
<view class="address">企业地址 {{ detail.address }}</view>
<text>{{ detail.introduction }}</text>
<view class="images-box">
<image v-for="(src, index) in detail.files" :key="index" :src="src" mode="widthFix" class="image"></image>
</view> </view>
<view> <view class="wd-flex" style="align-items: center">
<text class="address" style="margin-right: 8px">环保负责人</text> <text class="address" style="margin-right: 8px">环保负责人</text>
<text style="margin-right: 8px">{{ detail.enterprisesName }}</text> <text style="margin-right: 16px">{{ detail.enterprisesName }}</text>
<text class="address" style="margin-right: 8px">联系方式</text>
<text style="text-decoration: underline">{{ detail.environmentalContactPhone }}</text> <text style="text-decoration: underline">{{ detail.environmentalContactPhone }}</text>
</view> </view>
<view> <view class="images-box">
<text class="address" style="margin-right: 8px">成立时间</text> <image v-for="(src, index) in detail.files" :key="index" :src="src.url" mode="widthFix" class="image"></image>
<text>{{ $util.formatDate(detail.establishmentDate, 'YYYY年M月D日') }}</text>
</view> </view>
<view class="prove-list"> <text class="address">{{ detail.introduction }}</text>
<view class="prove" v-for="prove in detail.qualificationList" :key="prove.id"> </view>
<view class="box wd-text-12" v-for="prove in detail.qualificationList" :key="prove.id">
<view class="wd-flex" style="gap: 8px">
<image src="@/static/images/enterprise/zz.png" style="width: 90px; height: 70px" mode="widthFix"></image>
<view style="flex: 1; justify-content: space-between" class="wd-flex wd-flex-col">
<view class="wd-flex" style="gap: 8px; align-items: center">
<text class="label">资质名称</text>
<view> <view>
{{ $dict.echoDicValue(dictMap.enterprise_qua, prove.qualificationName.toString()) }} {{ $dict.echoDicValue(dictMap.enterprise_qua, prove.qualificationName.toString()) }}
</view> </view>
<view class=""> </view>
{{ $util.formatDate(prove.handleDate, 'YYYY年M月D日') }}- <view class="wd-flex" style="gap: 8px; align-items: center">
{{ $util.formatDate(prove.expiryDate, 'YYYY年M月D日') }} <text class="label">资质编号</text>
<view>
{{ prove.enterpriseAuth }}
</view>
</view>
<view class="wd-flex" style="gap: 8px; align-items: center">
<text class="label">资质时限</text>
<view>
{{ $util.formatDate(prove.handleDate, 'YYYY/M/D') }}~
{{ $util.formatDate(prove.expiryDate, 'YYYY/M/D') }}
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<!--
<view class="box">
<view class="wd-font-800">资质许可</view>
</view> -->
<view class="box">
<view class="wd-font-800">实时监控</view>
</view> </view>
<view class="box"> <view class="box">
<view class="wd-font-800">检查记录</view> <view class="wd-font-800">检查记录</view>
</view> </view>
<view class="button-box">
<view class="button">确认审核</view>
</view>
</view> </view>
</cs-page> </cs-page>
</template> </template>
@ -90,7 +101,9 @@ export default {
this.detail = res.data this.detail = res.data
}, },
goBack() { goBack() {
uni.navigateBack() uni.switchTab({
url: '/pages/enterprise'
})
} }
} }
} }
@ -99,6 +112,7 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.detail-container { .detail-container {
padding: 12px; padding: 12px;
position: relative;
.box { .box {
margin-bottom: 12px; margin-bottom: 12px;
background-color: #fff; background-color: #fff;
@ -110,6 +124,9 @@ export default {
flex-flow: column nowrap; flex-flow: column nowrap;
gap: 16px; gap: 16px;
.address { .address {
display: flex;
flex-flow: row nowrap;
gap: 5px;
color: $uni-text-color-grey; color: $uni-text-color-grey;
} }
} }
@ -122,21 +139,41 @@ export default {
border-radius: $cs-border-radius; border-radius: $cs-border-radius;
} }
} }
.prove-list {
display: flex;
flex-flow: column nowrap;
gap: 5px;
.prove {
border: 1px solid $uni-color-primary;
padding: 5px 10px;
border-radius: 6px;
color: $uni-color-primary;
background-color: #ecf5ff;
}
} }
.label {
color: $uni-text-color-grey;
} }
.icon-box { .icon-box {
position: absolute; position: absolute;
left: 0; left: 0;
} }
.button-box {
width: 100%;
bottom: 0;
position: fixed;
background-color: #fff;
display: flex;
left: 0;
padding: var(--Number-12px, 12px);
padding-bottom: 25px;
align-items: center;
gap: var(--Number-12px, 12px);
.button {
display: flex;
padding: var(--Number-12px, 12px) 0px;
justify-content: center;
align-items: center;
gap: var(--Number-12px, 12px);
flex: 1 0 0;
background: #17c653;
border-radius: var(--Number-4px, 4px);
background: var(--LightMode-Success-Success-Light, #eafff1);
color: var(--LightMode-Success-Success, #17c653);
text-align: center;
font-size: 16px;
font-style: normal;
font-weight: 500;
line-height: normal;
}
}
</style> </style>

10
sub/enterprise/edit.vue

@ -50,7 +50,7 @@
<u-icon slot="right" name="arrow-right"></u-icon> <u-icon slot="right" name="arrow-right"></u-icon>
</u-form-item> </u-form-item>
<!-- 企业照片 --> <!-- 企业照片 -->
<u-form-item label="企业照片" borderBottom labelPosition="top" labelWidth="80"> <u-form-item label="企业照片" prop="photo" borderBottom labelPosition="top" labelWidth="80">
<u-upload <u-upload
:fileList="info.form.photo" :fileList="info.form.photo"
@afterRead="addEnterprisePhoto" @afterRead="addEnterprisePhoto"
@ -190,7 +190,7 @@ export default {
type: 'string', type: 'string',
required: true, required: true,
message: '请选择企业类型', message: '请选择企业类型',
trigger: ['blur'] trigger: ['blur', 'change']
}, },
address: { address: {
required: true, required: true,
@ -206,6 +206,12 @@ export default {
required: true, required: true,
message: '请输入联系方式', message: '请输入联系方式',
trigger: ['blur'] trigger: ['blur']
},
photo: {
require: true,
min: 1,
message: '至少上传一张图片',
trigger: ['blur', 'change']
} }
} }
}, },

16
sub/owner/invite.vue

@ -12,14 +12,14 @@ export default {
}, },
onLoad(res) { onLoad(res) {
console.log('invite', res) console.log('invite', res)
getQrcode({ // getQrcode({
data: { // data: {
page: 'pages/login', // page: 'pages/login',
scene: `invateId=${this.$store.getters.userId}` // scene: `invateId=${this.$store.getters.userId}`
} // }
}).then(res => { // }).then(res => {
console.log(res) // console.log(res)
}) // })
}, },
onShareAppMessage() { onShareAppMessage() {
return { return {

3
uni.scss

@ -17,7 +17,7 @@ $uni-text-color-disable: #c0c0c0;
/* 背景颜色 */ /* 背景颜色 */
$uni-bg-color: #ffffff; $uni-bg-color: #ffffff;
$uni-bg-color-grey: #f8f8f8; $uni-bg-color-grey: #78829d;
$uni-bg-color-hover: #f1f1f1; //点击状态颜色 $uni-bg-color-hover: #f1f1f1; //点击状态颜色
$uni-bg-color-mask: rgba(0, 0, 0, 0.4); //遮罩颜色 $uni-bg-color-mask: rgba(0, 0, 0, 0.4); //遮罩颜色
@ -66,3 +66,4 @@ $uni-font-size-paragraph: 15px;
$cs-shadow-color: #eaeaea; $cs-shadow-color: #eaeaea;
$cs-border-radius: 8px; $cs-border-radius: 8px;
$cs-gap: 10px; $cs-gap: 10px;
$cs-main-color: #17c653;

7
uni_modules/s-components/s-header/index.vue

@ -7,7 +7,7 @@
<view v-else> <view v-else>
<view class="operation" v-if="isTab"> <view class="operation" v-if="isTab">
<view class="wd-flex wd-items-center" style="gap: 10px"> <view class="wd-flex wd-items-center" style="gap: 10px">
<u--image src="/static/favicon.png" width="20px" height="20px" mode="aspectFit"></u--image> <u--image src="/static/favicon.png" width="24px" height="24px" mode="aspectFit"></u--image>
<text class="title">{{ title }}</text> <text class="title">{{ title }}</text>
</view> </view>
</view> </view>
@ -49,9 +49,7 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.container { .container {
background-color: #fff; background-color: #fff;
box-shadow: 0 1px 2px 1px $cs-shadow-color;
z-index: 1; z-index: 1;
margin-bottom: 2px;
.fit-content { .fit-content {
height: 6vh; height: 6vh;
} }
@ -59,13 +57,12 @@ export default {
padding: 10px; padding: 10px;
.title { .title {
color: #000; color: #000;
font-size: 18px; font-size: 16px;
font-weight: bold; font-weight: bold;
} }
.icon-box { .icon-box {
padding: 5px; padding: 5px;
border-radius: 50%; border-radius: 50%;
box-shadow: 0 0 4px 2px $cs-shadow-color;
} }
} }
} }

2
uni_modules/s-components/s-tabber/index.vue

@ -95,7 +95,7 @@ export default {
<style lang="scss"> <style lang="scss">
.container { .container {
background-color: #fff; background-color: #fff;
box-shadow: 0 -1px 2px 1px $cs-shadow-color; // box-shadow: 0 -1px 2px 1px $cs-shadow-color;
} }
.noTab { .noTab {
// background-color: #fff; // background-color: #fff;

1
utils/dict.js

@ -5,6 +5,7 @@
*/ */
export function echoDicValue(dict, value) { export function echoDicValue(dict, value) {
if (!dict) return '' if (!dict) return ''
if (!value) return ''
return dict.find(d => d.value == value).label || '' return dict.find(d => d.value == value).label || ''
} }

63
wxcomponents/vant/dropdown-menu/index.wxss

@ -1 +1,62 @@
@import '../common/index.wxss';.van-dropdown-menu{background-color:var(--dropdown-menu-background-color,#fff);box-shadow:var(--dropdown-menu-box-shadow,0 2px 12px hsla(210,1%,40%,.12));display:flex;height:var(--dropdown-menu-height,50px);-webkit-user-select:none;user-select:none}.van-dropdown-menu__item{align-items:center;display:flex;flex:1;justify-content:center;min-width:0}.van-dropdown-menu__item:active{opacity:.7}.van-dropdown-menu__item--disabled:active{opacity:1}.van-dropdown-menu__item--disabled .van-dropdown-menu__title{color:var(--dropdown-menu-title-disabled-text-color,#969799)}.van-dropdown-menu__title{box-sizing:border-box;color:var(--dropdown-menu-title-text-color,#323233);font-size:var(--dropdown-menu-title-font-size,15px);line-height:var(--dropdown-menu-title-line-height,18px);max-width:100%;padding:var(--dropdown-menu-title-padding,0 24px 0 8px);position:relative}.van-dropdown-menu__title:after{border-color:transparent transparent currentcolor currentcolor;border-style:solid;border-width:3px;content:"";margin-top:-5px;opacity:.8;position:absolute;right:11px;top:50%;transform:rotate(-45deg)}.van-dropdown-menu__title--active{color:var(--dropdown-menu-title-active-text-color,#ee0a24)}.van-dropdown-menu__title--down:after{margin-top:-1px;transform:rotate(135deg)} @import '../common/index.wxss';
.van-dropdown-menu {
background-color: var(--dropdown-menu-background-color, #fff);
box-shadow: var(--dropdown-menu-box-shadow, 0 2px 12px hsla(210, 1%, 40%, .12));
display: flex;
height: var(--dropdown-menu-height, 50px);
-webkit-user-select: none;
user-select: none
}
.van-dropdown-menu__item {
align-items: center;
display: flex;
flex: 1;
justify-content: center;
min-width: 0
}
.van-dropdown-menu__item:active {
opacity: .7
}
.van-dropdown-menu__item--disabled:active {
opacity: 1
}
.van-dropdown-menu__item--disabled .van-dropdown-menu__title {
color: var(--dropdown-menu-title-disabled-text-color, #969799)
}
.van-dropdown-menu__title {
box-sizing: border-box;
color: var(--dropdown-menu-title-text-color, #323233);
font-size: var(--dropdown-menu-title-font-size, 15px);
line-height: var(--dropdown-menu-title-line-height, 18px);
max-width: 100%;
padding: var(--dropdown-menu-title-padding, 0 24px 0 8px);
position: relative;
}
.van-dropdown-menu__title:after {
border-color: transparent transparent currentcolor currentcolor;
border-style: solid;
border-width: 3px;
content: "";
margin-top: -5px;
opacity: .8;
position: absolute;
right: 11px;
top: 50%;
transform: rotate(-45deg)
}
.van-dropdown-menu__title--active {
color: var(--dropdown-menu-title-active-text-color, #ee0a24)
}
.van-dropdown-menu__title--down:after {
margin-top: -1px;
transform: rotate(135deg)
}
Loading…
Cancel
Save