浏览代码

'1.3.1.2'

哥哥玩剑魂呢 4 年之前
父节点
当前提交
f90651848f
共有 2 个文件被更改,包括 51 次插入17 次删除
  1. 11 8
      src/home.vue
  2. 40 9
      src/views/ranking/dept_rank.vue

+ 11 - 8
src/home.vue

@@ -397,7 +397,7 @@
 						</div>
 						<div v-if="announcement.title" class="announs">
 							<b style="font-size:15px;margin:10px 0 0 10px;display: inline-block;">{{announcement.title}}</b>
-							<div class="announDetails" style="padding:0 0 0 30px;margin-top:10px;" v-html="announcement.focus"></div>
+							<div class="announDetails" style="padding:0 0 0 18px;margin-top:10px;" v-html="announcement.focus"></div>
 						</div>
 						<div v-else class="nopoint_box">
 							<div class="noimg"></div>
@@ -1606,13 +1606,16 @@ export default {
 	// min-height: calc(60vh - 160px);
 	margin: 10px 0 0 0;
   }
-//   ::v-deep .announDetails{
-// 	max-height: 410px;
-//   	overflow-y: auto;
-// 	*{
-// 		color: #8c8c8c !important;
-// 	}
-//   }
+  ::v-deep .announDetails{
+	// max-height: 410px;
+  	// overflow-y: auto;
+	// *{
+	// 	color: #8c8c8c !important;
+	// }
+	// img{
+	// 	width: 100% !important;
+	// }
+  }
   .announDetails{
 	max-height: 410px;
   	overflow-y: auto;

+ 40 - 9
src/views/ranking/dept_rank.vue

@@ -171,11 +171,12 @@
 				<el-form-item label="规则分类" style="margin-left:20px">
 					<el-cascader
 						class="date-picker-width"
-						v-model="Dc_Data.rule_id"
+            			@change="ruleInquiredialog"
+						v-model="rule_ids"
 						:options="rule_trees"
 						:props="props"
 						 size="medium"
-						ref="rule"
+						ref="derive"
 						clearable
 						collapse-tags
 						placeholder="请选择规则分类"
@@ -230,6 +231,7 @@ import season from '@/components/season';
 export default {
 	data() {
 		return {
+			rule_ids:null,
 			Dc_Data: {
 				//导出数据
 				value1: '', //时间
@@ -330,6 +332,35 @@ export default {
 	},
 	components: { season },
 	methods: {
+		ruleInquiredialog(){
+			this.ruleUtif("derive")
+		},
+		ruleUtif(rule){
+			let ruleList = this.$refs[rule].getCheckedNodes()
+			let ruleId = []
+			ruleList.forEach(item=>{
+				ruleId.push(item.value)
+			})
+			if(rule == 'ruleinquire'){
+				this.formData.rule_id = ruleId
+			}else{
+				this.Dc_Data.rule_id = ruleId
+			}
+			this.$nextTick(()=>{
+				if(this.$refs[rule].presentTags[1]){
+				this.$refs[rule].presentTags[1].text = '+ '+(ruleId.length-1).toString()
+				}else{
+				if(ruleId.length>1){
+					let list = {
+					closable: false,
+					key: -1,
+					text: '+ '+(ruleId.length-1).toString()
+					}
+					this.$refs[rule].presentTags[1] = list
+				}
+				}
+			})
+		},
 		// 轮播页面跳转
 		swiperPage(formName) {
 			this.$refs[formName].validate(valid => {
@@ -498,13 +529,13 @@ export default {
 			}
 			this.Dc_Data.dept_name = dept_name;
 			//规则
-			let rule_id = [];
-			for (let i in this.Dc_Data.rule_id) {
-				for (let a in this.Dc_Data.rule_id[i]) {
-					rule_id.push(this.Dc_Data.rule_id[i][a]);
-				}
-			}
-			this.Dc_Data.rule_id = rule_id;
+			// let rule_id = [];
+			// for (let i in this.Dc_Data.rule_id) {
+			// 	for (let a in this.Dc_Data.rule_id[i]) {
+			// 		rule_id.push(this.Dc_Data.rule_id[i][a]);
+			// 	}
+			// }
+			// this.Dc_Data.rule_id = rule_id;
 			let data = '';
 			if (this.Dc_Data.value1) {
 				data += '&start_date=' + this.Dc_Data.value1[0];