347617796@qq.com 2 年之前
父节点
当前提交
9d05e1d036
共有 1 个文件被更改,包括 10 次插入27 次删除
  1. 10 27
      src/home.vue

+ 10 - 27
src/home.vue

@@ -1,6 +1,6 @@
 <template>
 	<div class="">
-		<div v-if="$supremeAuthority()!='dept_manager'&&$supremeAuthority()!='employee'&&user_info.is_only_try_order"  @click="dialogVisible = true" :style="{ backgroundImage: 'url(' + loginBg + ')' }"  style="position: relative;margin-bottom: 10px;height: 77px;" class="headerImg">
+		<div v-if="$supremeAuthority()!='dept_manager'&&$supremeAuthority()!='employee'&&user_info.is_only_try_order"  @click="bundleOfServices" :style="{ backgroundImage: 'url(' + loginBg + ')' }"  style="position: relative;margin-bottom: 10px;height: 77px;" class="headerImg">
 			<div style="position: absolute;width: 440px;font-size: 26px;color: #fff;font-weight: 600;top: 20px;text-align: center;left: 50%;margin-left: -220px;">
 				免费预约演示 获取行业管理方案
 			</div>
@@ -632,7 +632,6 @@ export default {
 		}
 	},
 	mounted() {
-		// this.initAjax();
 		this.thisweek=this.getTime(7)+'~'+this.getTime(1)
 		if (this.employeeRout) {
 			this.inCommonUse = [];
@@ -661,31 +660,15 @@ export default {
 		});
 	},
 	methods: {
-		initAjax(){
-			//(1).实例化ajax对象
-			let ajax=new XMLHttpRequest()
-			 //(2).设置请求方法和地址
-			ajax.open('get',process.env.VUE_APP_BASE_API+'/api/announcement/list');
-			//(3).设置请求头(post请求才需要设置)
-			ajax.setRequestHeader('Content-Type','application/x-www-form-urlencoded')
-			ajax.setRequestHeader('A-Token','eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOm51bGwsImlhdCI6MTY2OTk1MTE0OCwiZXhwIjotMSwibmJmIjoxNjY5OTUxMTQ4LCJqdGkiOiJNdTcwTnlEWHBhc3N4NXBQIiwic3ViIjoxODEsInBydiI6ImNhNjQ4OWQ1MGYyNDA3YTY3ODMwZTgwOTBkMDE0ODgzNTY4NTk2MmIiLCJyb2xlIjoiZW1wbG95ZWUifQ.kwLflzKZncId-G95vLe0K_TwogEHlxO8FzGay0Q7ubw')
-			 //(4).发送请求 : 参数格式  'key=value'
-			ajax.data='page=1&page_size=10'
-			ajax.send()
-			//(5).注册回调函数
-		    ajax.onreadystatechange = function() {
-		        //onreadystatechange会触发多次,一般需要判断xhr.readState == 4 才获取响应数据
-		        if (ajax.readyState == 4) {
-		          console.log(JSON.parse(ajax.response))
-		        }
-		    }
-			 ajax.onload = function() {
-			         //onreadystatechange会触发多次,一般需要判断xhr.readState == 4 才获取响应数据
-			  //        if (ajax.readyState == 4) {
-			           console.log(ajax)
-			  //        }
-			  }
-			
+		bundleOfServices(){
+			this.$dd.biz.util.openSlidePanel({
+				url:"https://page.dingtalk.com/wow/dingtalk/act/serviceconversation?wh_biz=tm&showmenu=false&goodsCode=DT_GOODS_881607043109331&corpId="+this.$getCache('corpId')+"&token=5784a3e6b5e025ee891517ea814180f4",
+				title: '客服群',
+				onSuccess : function(result) {},
+				onFail : function(err) {
+					console.log('onFail')
+				}
+			})
 		},
 		submitForm(formName) {
 			this.$refs[formName].validate((valid) => {