Browse Source

2023-11-8

master
guoxing 2 years ago
parent
commit
ff9dd21c51
  1. 157
      supervise-crm-ui/src/views/projectSet/WechatPush/index.vue
  2. 1
      supervise-crm-ui/src/views/projectSet/projectStaff/index.vue
  3. 3
      supervise-uniapp/App.vue
  4. 6
      supervise-uniapp/common/config.js

157
supervise-crm-ui/src/views/projectSet/WechatPush/index.vue

@ -16,12 +16,12 @@
<el-col :span="8" class="item" style="margin-left: 50px;">
<div class="listtop" style="width: 100%">
<div class="tit">关联人员</div>
<div
<!-- <div
style="display: flex;flex-direction: row; align-items: center; justify-content: space-between;padding-left: 20px;padding-right: 20px;">
<img src="../../../../public/image/association.png"
<img src="../../../public/image/association.png"
style="width: 35px;height: 25px; margin-right: 10px;" />
<span> 为已绑定微信公众号人员</span>
</div>
</div> -->
</div>
@ -35,64 +35,48 @@
<div :class="{ 'title': data.psid==='0' }">{{ node.label }}</div>
<div style="flex: 1;"></div>
<div style="margin-right: 35px;display: flex;flex-direction: row; align-items: center;">
<div style="margin-right: 15px;display: flex;flex-direction: row; align-items: center;">
<!-- <span v-if="node.childNodes.length!=0" :class="{ 'title': data.psid==='0' }">[ {{ node.childNodes.length}} ]</span> -->
<span v-if="data.psid==='0'" :class="{ 'title': data.psid==='0' }" style="margin-right: 20px;">关联微信
<span v-if="data.psid==='0'" :class="{ 'title': data.psid==='0' }" style="margin-right: 10px;">关联微信
</span>
<div v-if="node.childNodes.length==0"
style="width: 100%;display: flex;flex-direction: row;align-items: center;">
<div></div>
<img v-if="data.isOpenId=='2'" src="../../../../public/image/association.png"
style="width: 35px;height: 25px;" />
<span style="margin-left: 30px;width:100px; overflow: hidden;text-align: center;
<img v-if="data.isOpenId=='2'" src="../../../public/image/link.png"
style="width: 35px;height: 25px;margin-right: 30px;" />
<img v-if="data.isOpenId=='1'" src="../../../public/image/unlink.png"
style="width: 35px;height: 25px;margin-right: 30px;" />
<!-- <span style="margin-left: 30px;width:100px; overflow: hidden;text-align: center;
white-space: nowrap;
text-overflow: ellipsis;">正在完善 </span>
text-overflow: ellipsis;">正在完善 </span> -->
</div>
</div>
<!-- <span
v-if="node.childNodes.length===0"
class="history"
@click="jumpHistory(node.data)"
>查看历史录像
</span> -->
</div>
</el-tree>
</div>
<!-- <el-table ref="multipleTable" :data="dataListOne" highlight-current-row border max-height="500px"
style="width: 400px;height: 500px;" @row-click="singleElection2" tooltip-effect="dark"
:row-style="{height:'50px'}">
<el-table-column label="ID" align="center">
<template slot-scope="scope">
<div
style="display: flex;flex-direction: row; align-items: center; justify-content: space-between;padding-left: 20px;padding-right: 20px;">
<span>{{scope.row.name}}</span>
<img src="../../../public/image/association.png" style="width: 45px;height: 35px;"
v-show="scope.row.isOpenId=='2'" />
</div>
</template>
</el-table-column>
<el-table-column prop="orgName" label="单位" align="center" />
</el-table> -->
</el-col>
<el-col :span="8" class="item" style="margin-left: 50px;width:700px;">
<div class="listtop">
<div class="tit">微信推送</div>
<div
style="display: flex;flex-direction: row;align-items: center; height: 50px;padding: 10px;margin-left: -10px;">
<el-checkbox style="zoom: 150%;" :value="Wxstate" v-model="Wxstate" @change="Wxtitlecheckbox($event)"></el-checkbox>
<div class="tit" style="margin-left: 10px;">微信推送设置</div>
<span style="margin-left: 5px;">{{Wxtitle}}</span>
</div>
<div>
<span
style="color: #fff;background: #018AD2; font-size: 16px; margin-right: 20px; border-radius: 5px;padding: 4px 12px;"
@click="saveData()">保存</span>
@click="saveData()" v-show="sysorganList2.length>0">保存</span>
</div>
</div>
@ -201,7 +185,9 @@
ValSids: [],
sysorganList: [],
sysorganList2: [],
defaultExpandedKeys: [] //
defaultExpandedKeys: [], //
Wxtitle: '',
Wxstate: false
}
},
watch: {
@ -239,11 +225,13 @@
}
},
loadList() {
req.projectinformation().then(res => {
if (res.success) {
this.formobj = res.data
req.projectinformation().then(resp => {
if (resp.success) {
this.formobj = resp.data
console.log("projectinformation", resp.data)
req.associationUserList(res.data[0].sid).then(res => {
req.associationUserList(resp.data[0].sid).then(res => {
console.log("associationUserList", res.data)
this.sysorganList = res.data
this.defaultExpandedKeys = []
@ -278,7 +266,12 @@
},
singleElection(row) {
console.log("aaaaaaaaaa", row)
this.Wxtitle =''
this.Wxstate=false
this.sysorganList2=[]
req.associationUserList(row.sid).then(res => {
console.log("associationUserList", row.data)
this.sysorganList = res.data
this.defaultExpandedKeys = []
@ -291,20 +284,20 @@
console.log("sysorganList", this.sysorganList)
this.uploadData.userProjectSid = res.data[0].sid
req.templateMessage(this.dataListOne[0].sid).then(res => {
if (res.success) {
this.sysorganList2 = res.data
// this.uploadData.userProjectSid = res.data[0].sid
// req.templateMessage(res.data[0].sid).then(res => {
// if (res.success) {
// this.sysorganList2 = res.data
//this.Array
this.sysorganList2.forEach(item => {
// //this.Array
// this.sysorganList2.forEach(item => {
this.$set(item, 'Show', true)
// this.$set(item, 'Show', true)
})
}
})
// })
// }
// })
})
@ -320,7 +313,13 @@
this.$set(item, 'Show', true)
if (item.state == '2') {
count++
}
})
this.Wxstate = count == this.sysorganList2.length
}
})
@ -339,12 +338,24 @@
item.Show = !item.Show
console.log("aaaaaaaaaa", item)
},
titlecheckbox(id, info) {
console.log("aaaaaaaaaa", id)
console.log("aaaaaaaaaa", info)
Wxtitlecheckbox(checked) {
console.log("Wxtitlecheckbox", checked)
this.sysorganList2.forEach(item => {
this.$set(item, 'state', checked ? "2" : '1')
item.list.forEach(item => {
this.$set(item, 'state', checked ? "2" : '1')
})
})
},
titlecheckbox(id, info) {
console.log("aaaaaaaaaa", id)
console.log("aaaaaaaaaa", info)
const item = this.sysorganList2.find((item => item.id == id))
@ -356,8 +367,17 @@
})
var count = 0
this.sysorganList2.forEach(item => {
console.log("aaaaaaaaaa", item)
if (item.state == '2') {
count++
}
})
console.log("count", count)
this.Wxstate = count == this.sysorganList2.length
},
@ -384,6 +404,20 @@
console.log("aaaaaaaaaa", newList.length)
this.sysorganList2[index].state = count == newList.length ? "2" : "1"
var count2 = 0
this.sysorganList2.forEach(item => {
if (item.state == '2') {
count2++
}
})
console.log("count", count)
this.Wxstate = count2 == this.sysorganList2.length
},
saveData() {
@ -421,6 +455,8 @@
console.log("aaaaaaaaaa", val)
this.Wxtitle = " - " + val.name+" - " + val.orgAllName
console.log("aaaaaaaaaa", num)
@ -431,12 +467,23 @@
req.templateMessage(userProjectSid).then(res => {
if (res.success) {
this.sysorganList2 = res.data
var count = 0
//this.Array
this.sysorganList2.forEach(item => {
this.$set(item, 'Show', true)
if (item.state == '2') {
count++
}
})
console.log("count", count)
this.Wxstate = count == this.sysorganList2.length
}
})
}

1
supervise-crm-ui/src/views/projectSet/projectStaff/index.vue

@ -52,6 +52,7 @@
<div class="org-tree">
<eltree :data="sysorganList2" show-checkbox node-key="sid" :props="props" ref="tree2" highlight-current
check-strictly :default-checked-keys="uploadData.users"
:default-expand-all="true"
:default-expanded-keys="defaultExpandedKeys2"
@check="handleNodeClick2">
<div class="custom-tree-node" slot-scope="{ node, data }"

3
supervise-uniapp/App.vue

@ -1,10 +1,11 @@
<script>
import APPUpdate from "plugins/APPUpdate/index.js";
import config from "common/config.js";
export default {
globalData: {
// wxSilentLoginURL: "https://supervise.yxtsoft.com/portal/v1/wxuser/wxSilentLogin",
// wxSilentLoginURL: "https://supervise.yxtsoft.com/api/portal/v1/wxuser/wxSilentLogin",//
wxSilentLoginURL: "http://192.168.1.104:7009/v1/app/wxuser/wxSilentLogin",
wxSilentLoginURL: config.baseUrl+"/v1/app/wxuser/wxSilentLogin",
wxAuthLoginURL: "https://supervise.yxtsoft.com/api/portal/v1/wxuser/wxAuthLogin",
SilentLoginURL: "https://supervise.yxtsoft.com/api/portal/v1/wxuser/SilentLogin", //
token: "",

6
supervise-uniapp/common/config.js

@ -6,9 +6,9 @@
* loginTimeoutPage = "/pages/login/index", // 登录超时或失效的情况下,跳转到的登录页面
*/
module.exports = {
// baseUrl: 'http://jg.yyundong.com',// 测试
// baseUrl: 'https://supervise.yxtsoft.com/reportwxmpapi',//正式
baseUrl: 'http://192.168.1.104:7009',
// baseUrl: 'http://jg.yyundong.com/reportwxmpapi',// 测试
baseUrl: 'https://supervise.yxtsoft.com/reportwxmpapi',//正式
// baseUrl: 'http://192.168.1.104:7009',
// baseUrl: 'http://192.168.1.110:8112',
tokenName: "Authorization", // 请求头中token的名字,与服务器端对应
loginTimeoutCode: "5001", // 登录超时或失效的情况下,服务器端返回的错误码

Loading…
Cancel
Save