|
@@ -6,12 +6,18 @@
|
|
|
@click-left="onClickLeft"
|
|
|
/>
|
|
|
|
|
|
- <van-image
|
|
|
+ <!-- <van-image
|
|
|
width="100%"
|
|
|
height="10rem"
|
|
|
fit="cover"
|
|
|
src="https://img1.baidu.com/it/u=2086445453,3056906789&fm=253&fmt=auto&app=138&f=GIF?w=1378&h=400"
|
|
|
- />
|
|
|
+ /> -->
|
|
|
+
|
|
|
+ <van-swipe :autoplay="3000" lazy-render>
|
|
|
+ <van-swipe-item v-for="image in BannerImgurls" :key="image" >
|
|
|
+ <van-image width="100%" height="10rem" fit="cover" :src="image" />
|
|
|
+ </van-swipe-item>
|
|
|
+ </van-swipe>
|
|
|
|
|
|
<div class="tabtitlelay">
|
|
|
<div class="tabtitle1"></div>
|
|
@@ -41,9 +47,9 @@
|
|
|
</div>
|
|
|
|
|
|
<van-grid :border="false">
|
|
|
- <van-grid-item icon="photo-o" text="场所登记" @click="getsome2" />
|
|
|
- <van-grid-item icon="photo-o" text="场所人员信息" @click="getsome3" />
|
|
|
- <van-grid-item icon="photo-o" text="牌位管理" />
|
|
|
+ <van-grid-item icon="../../../loginbg/csdj.png" text="场所登记" />
|
|
|
+ <van-grid-item icon="../../../loginbg/csry.png" text="场所人员信息" />
|
|
|
+ <van-grid-item icon="../../../loginbg/cspw.png" text="牌位管理" />
|
|
|
</van-grid>
|
|
|
|
|
|
<div class="hLine"></div>
|
|
@@ -54,19 +60,20 @@
|
|
|
</div>
|
|
|
|
|
|
<van-grid :border="false" >
|
|
|
- <van-grid-item icon="photo-o" to="/placeActivityList" text="场所活动" />
|
|
|
- <van-grid-item icon="photo-o" to="/selfMeetingList" text="私设聚会点" />
|
|
|
- <van-grid-item icon="photo-o" to="/abnormalCrowd" text="信教群众异常" />
|
|
|
- <van-grid-item icon="photo-o" text="场所检查" />
|
|
|
- <van-grid-item icon="photo-o" text="安防设施异常" />
|
|
|
- <van-grid-item icon="photo-o" text="负责人会议" />
|
|
|
- <van-grid-item icon="photo-o" to="/setting" text="其他" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_cshd.png" to="/placeActivityList" text="场所活动" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_ssjhd.png" to="/selfMeetingList" text="私设聚会点" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_xjqz.png" to="/abnormalCrowd" text="信教群众异常" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_jc.png" text="场所检查" @click="tohd_jc" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_af.png" text="安防设施异常" @click="tohd_af" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_hy.png" text="负责人会议" @click="tohd_hy" />
|
|
|
+ <van-grid-item icon="../../../loginbg/hd_qt.png" to="/setting" text="其他" @click="tohd_qt" />
|
|
|
</van-grid>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import tool from "@/tool";
|
|
|
import qs from "qs";
|
|
|
+import onlineXm from "../../utils/onlineXm"
|
|
|
|
|
|
export default {
|
|
|
data() {
|
|
@@ -77,15 +84,15 @@ import qs from "qs";
|
|
|
password:"",
|
|
|
password2:"",
|
|
|
con1:"0",
|
|
|
+ BannerImgurls:['https://img1.baidu.com/it/u=2086445453,3056906789&fm=253&fmt=auto&app=138&f=GIF?w=1378&h=400','https://img1.baidu.com/it/u=2086445453,3056906789&fm=253&fmt=auto&app=138&f=GIF?w=1378&h=400']
|
|
|
}
|
|
|
},
|
|
|
|
|
|
created(){
|
|
|
let id=this.$route.query.id;
|
|
|
- this.getSome();
|
|
|
this.TokenLogin();
|
|
|
-
|
|
|
-
|
|
|
+ this.getBannerImg();//获取轮播图
|
|
|
+ this.getSelectColor();//获取主题颜色
|
|
|
},
|
|
|
|
|
|
methods:{
|
|
@@ -96,59 +103,82 @@ import qs from "qs";
|
|
|
onClickLeft(){
|
|
|
history.back();
|
|
|
},
|
|
|
+ tohd_jc(){
|
|
|
+ //this.onlineXm.xmNavTo("../activityMan\siteInspection\siteInspectionList");
|
|
|
+ this.$router.push("/siteInspectionList");
|
|
|
+ },
|
|
|
+ tohd_af(){
|
|
|
+ this.$router.push("/securityFacilitiesErrList");
|
|
|
+ },
|
|
|
+ tohd_hy(){
|
|
|
+ this.$router.push("/religiousConferenceList");
|
|
|
+ },
|
|
|
+ tohd_qt(){
|
|
|
+ this.$router.push("/securityFacilitiesErrList");
|
|
|
+ },
|
|
|
|
|
|
async TokenLogin(){
|
|
|
|
|
|
let that=this;
|
|
|
|
|
|
- //SDK中 getToken() 方法获取免登token
|
|
|
- // window.xm.getToken().then(async function(token){
|
|
|
- // console.log(token);
|
|
|
-
|
|
|
- // const inputForm ={
|
|
|
- // 'token': token
|
|
|
- // }
|
|
|
- // var res = await this.$API.yin.TokenLogin.get(inputForm);
|
|
|
-
|
|
|
- // })
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
//添加PCtoken过期判断,(请求拦截到token过期,会设置PCtoken为空,为空的时候再调用免登功能)
|
|
|
if(this.$store.state.pctoken==""||this.$store.state.pctoken==undefined){
|
|
|
- const inputForm =qs.stringify({
|
|
|
- 'token': "ssssssss"
|
|
|
- }, { allowDots: true, arrayFormat: 'indices' })
|
|
|
- var res = await this.$API.yin.TokenLogin.get(inputForm);
|
|
|
- //console.log(res);
|
|
|
- //存PCtoken
|
|
|
- this.$store.commit('setPcToken',res.PcToken);
|
|
|
- this.$store.commit('setUser',res.account);
|
|
|
- }
|
|
|
|
|
|
+ //SDK中 getToken() 方法获取免登token
|
|
|
+ //window.xm.getToken().then(async function(token){//上线取消注释
|
|
|
+ let token="test";//上线注释
|
|
|
|
|
|
+ const inputForm =qs.stringify({
|
|
|
+ 'token': token
|
|
|
+ }, { allowDots: true, arrayFormat: 'indices' })
|
|
|
+ var res = await this.$API.yin.TokenLogin.get(inputForm);
|
|
|
+ //存PCtoken
|
|
|
+ this.$store.commit('setPcToken',res.PcToken);
|
|
|
+ this.$store.commit('setUser',res.account);
|
|
|
|
|
|
- //this.$store.commit('setUser',data);
|
|
|
- // if (res.type == 1) {
|
|
|
- // this.$router.replace({
|
|
|
- // path: "/main",
|
|
|
- // });
|
|
|
- // } else {
|
|
|
- // Toast.fail(res.message);
|
|
|
- // }
|
|
|
+ //})//上线取消注释
|
|
|
+
|
|
|
+ }
|
|
|
|
|
|
},
|
|
|
|
|
|
+ //获取轮播图
|
|
|
+ async getBannerImg(){
|
|
|
+ const inputForm =qs.stringify({
|
|
|
+ 'current': 1,
|
|
|
+ 'size': 5,
|
|
|
+ 'orders':[],
|
|
|
+ }, { allowDots: true, arrayFormat: 'indices' })
|
|
|
+ var res = await this.$API.my.BannerImg.get(inputForm);
|
|
|
+ let bs=[];
|
|
|
+ for(let i=0;i<res.records.length;i++){
|
|
|
+ bs.push(res.records[i].bannerImg);
|
|
|
+ }
|
|
|
+ //需添加url拼接
|
|
|
+ //this.BannerImgurls=bs;
|
|
|
+ //console.log(this.BannerImgurls);
|
|
|
+ },
|
|
|
|
|
|
- getSome(){
|
|
|
+ //获取主题颜色
|
|
|
+ async getSelectColor(){
|
|
|
+ const inputForm =qs.stringify({
|
|
|
+ 'current': 1,
|
|
|
+ 'size': 5,
|
|
|
+ 'orders':[],
|
|
|
+ }, { allowDots: true, arrayFormat: 'indices' })
|
|
|
+ var res = await this.$API.my.SelectColor.get(inputForm);
|
|
|
+ //默认取出列表第一条的色值使用,注意轻应用文档中(后面直接跟6位十六进制色值,不需要#)
|
|
|
+ console.log(res.records[0].selectColor.substring(1, 7));
|
|
|
+ //存PCtoken
|
|
|
+ this.$store.commit('setSelectColor',res.records[0].selectColor.substring(1, 7));
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
- async getsome2(){
|
|
|
-
|
|
|
+ //测试接口,可删除
|
|
|
+ async gettest(){
|
|
|
let that=this;
|
|
|
- this.$router.push("/placeRegister");
|
|
|
+
|
|
|
//SDK中 getToken() 方法获取免登token
|
|
|
window.xm.getToken().then(function(token){
|
|
|
console.log(token);
|
|
@@ -160,18 +190,13 @@ import qs from "qs";
|
|
|
|
|
|
})
|
|
|
|
|
|
+ //测试数据同步接口的
|
|
|
const inputForm ={
|
|
|
'iamRequestId': '120010',
|
|
|
'iamRemoteUser': 'admin12022',
|
|
|
'iamRemotePwd': ''
|
|
|
- }
|
|
|
- // login(inputForm).then(({data}) => {
|
|
|
- // this.$store.commit('setUser',data);
|
|
|
- // })
|
|
|
-
|
|
|
- //var res = await this.$API.yin.TokenLogin.post(inputForm);
|
|
|
+ }
|
|
|
var res = await this.$API.yin.SchemaService.post(inputForm);
|
|
|
-
|
|
|
if (res.type == 1) {
|
|
|
this.$router.replace({
|
|
|
path: "/main",
|
|
@@ -182,9 +207,8 @@ import qs from "qs";
|
|
|
|
|
|
},
|
|
|
|
|
|
- async getsome3(){
|
|
|
- console.log("11");
|
|
|
- this.$router.push("/placePerson");
|
|
|
+ //测试接口,可删除
|
|
|
+ async gettest2(){
|
|
|
var datas = {
|
|
|
username: "admin",
|
|
|
};
|
|
@@ -195,7 +219,7 @@ import qs from "qs";
|
|
|
|
|
|
|
|
|
//用户数据同步测试用(用户保存)
|
|
|
- async getUser1(){
|
|
|
+ async gettestUser1(){
|
|
|
const inputForm ={
|
|
|
'iamRequestId': '120010',
|
|
|
'iamRemoteUser': 'admin',
|
|
@@ -212,11 +236,10 @@ import qs from "qs";
|
|
|
'sign': '个性签名2',
|
|
|
}
|
|
|
var res = await this.$API.yin.UserCreateService.post(inputForm);
|
|
|
-
|
|
|
console.log(res);
|
|
|
},
|
|
|
//(用户更新)
|
|
|
- async getUser2(){
|
|
|
+ async gettestUser2(){
|
|
|
const inputForm ={
|
|
|
'iamRequestId': '120010',
|
|
|
'iamRemoteUser': 'admin',
|
|
@@ -238,7 +261,7 @@ import qs from "qs";
|
|
|
|
|
|
},
|
|
|
//(用户删除)
|
|
|
- async getUser3(){
|
|
|
+ async gettestUser3(){
|
|
|
const inputForm ={
|
|
|
'iamRequestId': '120010',
|
|
|
'iamRemoteUser': 'admin',
|
|
@@ -247,7 +270,6 @@ import qs from "qs";
|
|
|
}
|
|
|
var res = await this.$API.yin.UserDeleteService.post(inputForm);
|
|
|
console.log(res);
|
|
|
-
|
|
|
},
|
|
|
|
|
|
},
|
|
@@ -257,4 +279,5 @@ import qs from "qs";
|
|
|
|
|
|
<style>
|
|
|
|
|
|
+
|
|
|
</style>
|