通告功能

This commit is contained in:
13405411873 2025-04-25 21:43:22 +08:00
parent c03efe220a
commit c76258b433
7 changed files with 192 additions and 129 deletions

View File

@ -1,23 +1,23 @@
{
"name" : "多点通告",
"appid" : "__UNI__5491739",
"description" : "",
"versionName" : "1.1.0",
"versionCode" : "100",
"transformPx" : false,
"app-plus" : {
"usingComponents" : true,
"nvueCompiler" : "uni-app",
"splashscreen" : {
"alwaysShowBeforeRender" : true,
"waiting" : true,
"autoclose" : true,
"delay" : 0
"name": "多点通告",
"appid": "__UNI__5491739",
"description": "",
"versionName": "1.1.0",
"versionCode": "100",
"transformPx": false,
"app-plus": {
"usingComponents": true,
"nvueCompiler": "uni-app",
"splashscreen": {
"alwaysShowBeforeRender": true,
"waiting": true,
"autoclose": true,
"delay": 0
},
"modules" : {},
"distribute" : {
"android" : {
"permissions" : [
"modules": {},
"distribute": {
"android": {
"permissions": [
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
@ -35,35 +35,35 @@
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
]
},
"ios" : {},
"sdkConfigs" : {}
"ios": {},
"sdkConfigs": {}
}
},
"quickapp" : {},
"mp-weixin" : {
"optimization" : {
"subPackages" : true
"quickapp": {},
"mp-weixin": {
"optimization": {
"subPackages": true
},
"appid" : "wxd96fda6510adb6d3",
"setting" : {
"urlCheck" : false,
"es6" : false,
"minified" : true,
"postcss" : true
"appid": "wxd96fda6510adb6d3",
"setting": {
"urlCheck": false,
"es6": false,
"minified": true,
"postcss": true
},
"usingComponents" : true
"usingComponents": true
},
"vueVersion" : "2",
"h5" : {
"template" : "static/index.html",
"devServer" : {
"port" : 9090,
"https" : false
"vueVersion": "2",
"h5": {
"template": "static/index.html",
"devServer": {
"port": 9090,
"https": false
},
"title" : "RuoYi-App",
"router" : {
"mode" : "hash",
"base" : "./"
"title": "RuoYi-App",
"router": {
"mode": "history",
"base": ""
}
}
}

View File

@ -2,7 +2,9 @@
"dependencies": {
"cos-js-sdk-v5": "^1.8.7",
"html2canvas": "^1.4.1",
"rich-text-parser": "^1.0.2"
"jweixin-module": "^1.6.0",
"rich-text-parser": "^1.0.2",
"weixin-js-sdk": "^1.6.5"
},
"devDependencies": {
"rich-text-parser": "^1.0.2"

View File

@ -144,6 +144,15 @@
placeholder="最高" />
</view>
</view>
<view class="uni-form-item uni-column">
<view class="title">地区</view>
<view class="dl-drawer-item">
<uni-data-picker placeholder="请选择" popup-title="请选择地址" :localdata="dataTree"
v-model="queryParams.cityId" @change="onchange" @nodeclick="onnodeclick"
@popupopened="onpopupopened" @popupclosed="onpopupclosed">
</uni-data-picker>
</view>
</view>
<view style="display: flex;margin-top: 10rpx;">
<button class="mini-btn" type="default" size="mini" @click="reset()">重置</button>
<button class="mini-btn" type="warn" size="mini"
@ -191,12 +200,17 @@
import {
changeUserType
} from '@/utils/common.js'
import {
treeCity
} from '@/api/business/base.js'
export default {
components: {
noticeItem
},
data() {
return {
//
dataTree: [],
menus: ['全部', '最新', '平台结算', '急招', '品牌置换'],
menuIndex: 0,
dataList: [],
@ -243,6 +257,7 @@
this.initData("dl_blogger_type", "bloggerTypeList")
this.getByCodeInfo()
this.selectDataList()
this.initAddress()
//
// this.checkRights()
},
@ -250,6 +265,25 @@
},
methods: {
/**初始化树结构*/
initAddress() {
treeCity().then(res => {
res.data.forEach(it => {
if (it.children) {
it.children.forEach(item => {
item.children = null
})
}
})
this.dataTree = res.data
}).catch((e) => {
uni.showToast({
icon: 'error',
duration: 2000,
title: e
});
})
},
/**
* 去发布
*/

View File

@ -45,6 +45,9 @@
hasRights
} from '@/utils/common.js'
import rightsCode from '@/utils/rightsCode'
import {
getMemberDetail
} from '@/api/business/member.js'
export default {
components: {
tabBarVue,
@ -124,7 +127,18 @@
async changeMenu(code) {
this.nowUserType = getUserType()
if ("fabu" == code) {
getMemberDetail().then(res => {
if (!res.data.identityType) {
uni.showToast({
title: '暂未通告主认证,请先认证',
icon: 'none',
duration: 1000
})
} else {
this.$tab.navigateTo('/pages/notice/public-notice')
}
})
} else {
if (code == 'dingyue') {
if (!await this.checkIfHasRights(rightsCode.subscribeSelect)) {

View File

@ -160,14 +160,14 @@
}
}
},
onShow(){
if (getToken()){
onShow() {
if (getToken()) {
this.initMyCoupon()
}
},
methods: {
initMyCoupon(){
getMemberCoupon().then(res=>{
initMyCoupon() {
getMemberCoupon().then(res => {
this.coupon = res.data
})
},
@ -194,12 +194,12 @@
/*#endif*/
/*#ifdef H5*/
// H5
if (!getToken()) {
//
getCodeUrl("01", "pages/mine/coupon/my-coupon").then(res => {
window.location.href = res.codeUrl;
})
}
/*#endif*/
/*#ifdef MP-WEIXIN*/
//

View File

@ -185,18 +185,10 @@
let userTypeTemp = options.userType
this.initData(userTypeTemp);
//urlsearch
if (location.search) {
let search = location.search.slice(1);
let arr = search.split("&");
let result = {};
arr.forEach(function(item) {
let itemArr = item.split('=');
result[itemArr[0]] = itemArr[1];
})
if (result.code) {
userTypeTemp = result.state
if (options.code) {
userTypeTemp = options.state
let that = this
getWebAccessTokenAndOpenid(result.code).then(res => {
getWebAccessTokenAndOpenid(options.code).then(res => {
that.$store.dispatch('GzhLogin', res).then(() => {
that.initData(userTypeTemp);
that.loginSuccess()
@ -211,8 +203,6 @@
} else {
this.toLogin(userTypeTemp)
}
}
},
methods: {
openVip() {
@ -238,12 +228,12 @@
/*#endif*/
/*#ifdef H5*/
// H5
if (!getToken()) {
//
getCodeUrl(userType, "pages/mine/member/member-card").then(res => {
window.location.href = res.codeUrl;
})
}
/*#endif*/
/*#ifdef MP-WEIXIN*/
//

View File

@ -155,7 +155,7 @@
地区要求
</view>
<view class="item-value">
<uni-data-picker placeholder="请选择" popup-title="请选择收件地址" :localdata="dataTree"
<uni-data-picker placeholder="请选择" popup-title="请选择地址" :localdata="dataTree"
v-model="dataObj.cityId" @change="onchange" @nodeclick="onnodeclick"
@popupopened="onpopupopened" @popupclosed="onpopupclosed">
</uni-data-picker>
@ -257,9 +257,7 @@
<script>
import navigationBarVue from '@/components/navigation/navigationBar.vue';
import {
toast
} from '@/utils/common.js'
import upload from '@/utils/upload'
import {
uniListByParentCode
@ -273,6 +271,12 @@
getNoticeDetail
} from '@/api/business/notice';
import fuckTextarea from '@/components/fuck-textarea/fuck-textarea.vue'
import {
toast,
hasRights
} from '@/utils/common.js'
import constant from '@/utils/constant';
import rightsCode from '@/utils/rightsCode'
export default {
components: {
navigationBarVue,
@ -369,6 +373,22 @@
}
},
methods: {
/**
* 鉴权通用方法
* @param {Object} rigthsCode
*/
async checkIfHasRights() {
let res = await hasRights(rightsCode.reportInfoCollect)
if (!res) {
uni.showToast({
title: '如有需要请开通通告主卡',
icon: 'none',
duration: 1000
})
return false
}
return true
},
getSameNotice(sameId) {
getNoticeDetail({
noticeId: sameId
@ -610,7 +630,11 @@
/**
* 添加字段
*/
addNewField() {
async addNewField() {
//
if (!await this.checkIfHasRights(rightsCode.reportInfoCollect)) {
return
}
this.$refs.inputDialogCus.open()
},
//
@ -1082,4 +1106,3 @@
margin-right: 0 !important;
}
</style>