提交 d90f80d8 authored 作者: lidongxu's avatar lidongxu

fix(bi/store): 旺店通店铺_修复完成

同上
上级 ad7b8a83
...@@ -60,11 +60,14 @@ ...@@ -60,11 +60,14 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 50vh; height: 50vh;
padding: 20px;
.el-dialog__header{ .el-dialog__header{
padding-top: 10px;
height: 40px; height: 40px;
} }
.el-dialog__body { .el-dialog__body {
margin-top: 20px;
height: calc(50vh - 40px - 32px); height: calc(50vh - 40px - 32px);
} }
} }
......
...@@ -129,7 +129,8 @@ aside { ...@@ -129,7 +129,8 @@ aside {
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
padding: 20px; padding: 20px;
>div{
>div {
width: 100%; width: 100%;
padding: 20px; padding: 20px;
} }
......
...@@ -20,12 +20,12 @@ import { parseTime } from './date' ...@@ -20,12 +20,12 @@ import { parseTime } from './date'
*/ */
export function formatDate(cellValue) { export function formatDate(cellValue) {
if (cellValue == null || cellValue == "") return ""; if (cellValue == null || cellValue == "") return "";
var date = new Date(cellValue) var date = new Date(cellValue)
var year = date.getFullYear() var year = date.getFullYear()
var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1 var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1
var day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate() var day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate()
var hours = date.getHours() < 10 ? '0' + date.getHours() : date.getHours() var hours = date.getHours() < 10 ? '0' + date.getHours() : date.getHours()
var minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes() var minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
var seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() var seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds()
return year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds return year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds
} }
...@@ -233,7 +233,7 @@ export function getTime(type) { ...@@ -233,7 +233,7 @@ export function getTime(type) {
export function debounce(func, wait, immediate) { export function debounce(func, wait, immediate) {
let timeout, args, context, timestamp, result let timeout, args, context, timestamp, result
const later = function() { const later = function () {
// 据上一次触发时间间隔 // 据上一次触发时间间隔
const last = +new Date() - timestamp const last = +new Date() - timestamp
...@@ -250,7 +250,7 @@ export function debounce(func, wait, immediate) { ...@@ -250,7 +250,7 @@ export function debounce(func, wait, immediate) {
} }
} }
return function(...args) { return function (...args) {
context = this context = this
timestamp = +new Date() timestamp = +new Date()
const callNow = immediate && !timeout const callNow = immediate && !timeout
...@@ -345,7 +345,7 @@ export function makeMap(str, expectsLowerCase) { ...@@ -345,7 +345,7 @@ export function makeMap(str, expectsLowerCase) {
? val => map[val.toLowerCase()] ? val => map[val.toLowerCase()]
: val => map[val] : val => map[val]
} }
export const exportDefault = 'export default ' export const exportDefault = 'export default '
export const beautifierConf = { export const beautifierConf = {
...@@ -402,17 +402,27 @@ export function camelCase(str) { ...@@ -402,17 +402,27 @@ export function camelCase(str) {
export function isNumberStr(str) { export function isNumberStr(str) {
return /^[+-]?(0|([1-9]\d*))(\.\d+)?$/g.test(str) return /^[+-]?(0|([1-9]\d*))(\.\d+)?$/g.test(str)
} }
// 清除对象里属性的非响应式的值 // 清除对象里属性的非响应式的值
/**
* 深度重置对象的属性值
* @param {Object} obj - 需要重置的对象
* @param {Array} props - 需要重置的属性数组
*/
export function resetObjValue(obj, props) { export function resetObjValue(obj, props) {
for (let prop in obj) { for (let prop in obj) {
if (obj.hasOwnProperty(prop)) { if (obj.hasOwnProperty(prop)) {
// 判断属性值是否为数组或对象
if (Array.isArray(obj[prop])) { if (Array.isArray(obj[prop])) {
obj[prop] = []; obj[prop] = [];
obj[prop].forEach((item, index) => {
if (typeof item === 'object' && item !== null) {
resetObjValue(obj[prop], Object.keys(item));
}
});
} else if (typeof obj[prop] === 'object' && obj[prop] !== null) { } else if (typeof obj[prop] === 'object' && obj[prop] !== null) {
obj[prop] = {}; obj[prop] = {};
resetObjValue(obj[prop], Object.keys(obj[prop]));
} else { } else {
obj[prop] = undefined; // 基础类型重置为 undefined obj[prop] = undefined; // 基础类型重置为 undefined
} }
......
...@@ -68,12 +68,11 @@ ...@@ -68,12 +68,11 @@
popper-class="my_popper"></el-cascader> popper-class="my_popper"></el-cascader>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" <template #footer>
class="dialog-footer">
<el-button type="primary" <el-button type="primary"
@click="submitForm">确 定</el-button> @click="submitForm">确 定</el-button>
<el-button @click="cancel">取 消</el-button> <el-button @click="cancel">取 消</el-button>
</div> </template>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
...@@ -341,10 +340,6 @@ getSeriesGoodsTagList() ...@@ -341,10 +340,6 @@ getSeriesGoodsTagList()
} }
} }
} }
.dialog-footer {
align-self: flex-end;
}
} }
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论