lb #1
@@ -96,7 +96,7 @@ http.adornData = (data = {}, openDefaultdata = true, contentType = 'json') => {
 | 
				
			|||||||
    't': new Date().getTime()
 | 
					    't': new Date().getTime()
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  data = openDefaultdata ? merge(defaults, data) : data
 | 
					  data = openDefaultdata ? merge(defaults, data) : data
 | 
				
			||||||
  return contentType === 'json' ? JSON.stringify(data) : qs.stringify(data)
 | 
					  return contentType === 'raw' ? data : contentType === 'json' ? JSON.stringify(data) : qs.stringify(data)
 | 
				
			||||||
  // return contentType === 'json' ? JSON.stringify(data, (_, v) => typeof v === 'bigint' ? v.toString() : v) : qs.stringify(data)
 | 
					  // return contentType === 'json' ? JSON.stringify(data, (_, v) => typeof v === 'bigint' ? v.toString() : v) : qs.stringify(data)
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -279,24 +279,24 @@ export default {
 | 
				
			|||||||
				this.$http({
 | 
									this.$http({
 | 
				
			||||||
					url: this.$http.adornUrl('/monitoring/product'),
 | 
										url: this.$http.adornUrl('/monitoring/product'),
 | 
				
			||||||
					method: 'delete',
 | 
										method: 'delete',
 | 
				
			||||||
					headers: {
 | 
										data: ids
 | 
				
			||||||
						'Content-Type': 'application/json'
 | 
										// or : data: this.$http.adornData(ids, false, 'raw')
 | 
				
			||||||
					},
 | 
					 | 
				
			||||||
					data: this.$http.adornData(ids, false)
 | 
					 | 
				
			||||||
				}).then(({ data }) => {
 | 
					 | 
				
			||||||
					if (data && data.code === 0) {
 | 
					 | 
				
			||||||
						this.$message({
 | 
					 | 
				
			||||||
							message: '操作成功',
 | 
					 | 
				
			||||||
							type: 'success',
 | 
					 | 
				
			||||||
							duration: 1500,
 | 
					 | 
				
			||||||
							onClose: () => {
 | 
					 | 
				
			||||||
								this.getDataList()
 | 
					 | 
				
			||||||
							}
 | 
					 | 
				
			||||||
						})
 | 
					 | 
				
			||||||
					} else {
 | 
					 | 
				
			||||||
						this.$message.error(data.msg)
 | 
					 | 
				
			||||||
					}
 | 
					 | 
				
			||||||
				})
 | 
									})
 | 
				
			||||||
 | 
										// or: this.$http.delete(this.$http.adornUrl('/monitoring/product'), { data: this.$http.adornData(ids, false) })
 | 
				
			||||||
 | 
										.then(({ data }) => {
 | 
				
			||||||
 | 
											if (data && data.code === 0) {
 | 
				
			||||||
 | 
												this.$message({
 | 
				
			||||||
 | 
													message: '操作成功',
 | 
				
			||||||
 | 
													type: 'success',
 | 
				
			||||||
 | 
													duration: 1500,
 | 
				
			||||||
 | 
													onClose: () => {
 | 
				
			||||||
 | 
														this.getDataList()
 | 
				
			||||||
 | 
													}
 | 
				
			||||||
 | 
												})
 | 
				
			||||||
 | 
											} else {
 | 
				
			||||||
 | 
												this.$message.error(data.msg)
 | 
				
			||||||
 | 
											}
 | 
				
			||||||
 | 
										})
 | 
				
			||||||
			})
 | 
								})
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user