提交 91594ddb 编写于 作者: JEECG低代码平台's avatar JEECG低代码平台

1.项目样式 scss 全部转换为 less,且移除了项目 node-sass 依赖;

2.online开发ButtonExpHandler is not defined #957;
3.关于打包后JS文件过大,导致加载缓慢的建议 #969
上级 4c0c0945
......@@ -6,19 +6,19 @@ function resolve (dir) {
}
module.exports = {
context: path.resolve(__dirname, './'),
resolve: {
extensions: ['.js', '.vue', '.json'],
alias: {
'config': resolve('config'),
'@': resolve('src'),
'@views': resolve('src/views'),
'@comp': resolve('src/components'),
'@core': resolve('src/core'),
'@utils': resolve('src/utils'),
'@entry': resolve('src/entry'),
'@router': resolve('src/router'),
'@store': resolve('src/store')
}
},
}
\ No newline at end of file
context: path.resolve(__dirname, './'),
resolve: {
extensions: ['.js', '.vue', '.json'],
alias: {
'config': resolve('config'),
'@': resolve('src'),
'@views': resolve('src/views'),
'@comp': resolve('src/components'),
'@core': resolve('src/core'),
'@utils': resolve('src/utils'),
'@entry': resolve('src/entry'),
'@router': resolve('src/router'),
'@store': resolve('src/store')
}
}
}
......@@ -54,8 +54,6 @@
"html-webpack-plugin": "^4.0.0-beta.11",
"less": "^3.9.0",
"less-loader": "^4.1.0",
"node-sass": "^4.13.1",
"sass-loader": "^7.3.1",
"vue-template-compiler": "^2.6.10"
},
"eslintConfig": {
......@@ -65,7 +63,7 @@
},
"extends": [
"plugin:vue/strongly-recommended",
"eslint:recommended"
"@vue/standard"
],
"parserOptions": {
"parser": "babel-eslint"
......@@ -93,7 +91,9 @@
"vue/no-use-v-if-with-v-for": 0,
"vue/html-closing-bracket-newline": 0,
"vue/no-parsing-error": 0,
"no-console": 0
"no-console": 0,
"no-tabs": 0,
"indent": [1, 4]
}
},
"postcss": {
......@@ -104,6 +104,6 @@
"browserslist": [
"> 1%",
"last 2 versions",
"not ie <= 8"
"not ie <= 10"
]
}
......@@ -42,7 +42,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.chart-card-header {
position: relative;
overflow: hidden;
......
......@@ -83,6 +83,6 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
@import "chart";
</style>
\ No newline at end of file
......@@ -64,6 +64,6 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
@import "chart";
</style>
\ No newline at end of file
......@@ -71,6 +71,6 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
@import "chart";
</style>
\ No newline at end of file
......@@ -34,7 +34,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.chart-mini-progress {
padding: 5px 0;
position: relative;
......
......@@ -32,7 +32,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.rank {
padding: 0 32px 32px 72px;
......
......@@ -52,7 +52,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.chart-trend {
display: inline-block;
font-size: 14px;
......
......@@ -125,7 +125,7 @@
}
</script>
<style lang="scss">
<style lang="less">
.j-modal-box {
&.fullscreen {
......@@ -180,8 +180,5 @@
}
}
/deep/ {
}
}
</style>
\ No newline at end of file
......@@ -420,7 +420,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.j-super-query-box {
display: inline-block;
......
......@@ -829,7 +829,7 @@
}
</script>
<style lang="scss">
<style lang="less">
.card-container {
background: #fff;
overflow: hidden;
......@@ -877,7 +877,7 @@
}
}
</style>
<style lang="scss" scoped>
<style lang="less" scoped>
.container-widthEn{
width: 755px;
}
......
......@@ -132,27 +132,25 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.j-select-biz-component-box {
$width: 82px;
@width: 82px;
.left {
width: calc(100% - #{$width} - 8px);
width: calc(100% - @width - 8px);
}
.right {
width: #{$width};
width: @width ;
}
.full {
width: 100%;
}
/deep/ {
.ant-select-search__field {
/deep/ .ant-select-search__field {
display: none !important;
}
}
}
</style>
\ No newline at end of file
......@@ -43,4 +43,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -34,4 +34,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -35,4 +35,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -33,7 +33,7 @@
}
</script>
<style lang="scss">
<style lang="less">
/*
* The following styles are auto-applied to elements with
......
......@@ -60,7 +60,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.extra-img {
margin-top: -60px;
text-align: center;
......
......@@ -49,7 +49,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
#userLayout.user-layout-wrapper {
height: 100%;
......
......@@ -72,18 +72,18 @@
}
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
/* update_begin author:sunjianlei date:20190509 for: 修改侧边导航栏滚动条的样式 */
.sider {
$scrollBarSize: 10px;
@scrollBarSize: 10px;
ul.ant-menu {
/* 定义滚动条高宽及背景 高宽分别对应横竖滚动条的尺寸*/
&::-webkit-scrollbar {
width: $scrollBarSize;
height: $scrollBarSize;
width: @scrollBarSize;
height: @scrollBarSize;
background-color: transparent;
display: none;
}
......@@ -109,7 +109,7 @@
/* 定义滑块 */
&::-webkit-scrollbar-thumb {
border-radius: $scrollBarSize;
border-radius: @scrollBarSize;
background-color: #eee;
box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.1);
......
......@@ -22,7 +22,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.footer {
padding: 0 16px;
margin: 48px 0 24px;
......
......@@ -174,7 +174,7 @@
</script>
<style lang="scss">
<style lang="less">
body {
// 打开滚动条固定显示
overflow-y: scroll;
......
......@@ -100,7 +100,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.page-header {
background: #fff;
......
......@@ -84,7 +84,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.content {
margin: 24px 24px 0;
......
......@@ -47,7 +47,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.header-notice{
display: inline-block;
transition: all 0.3s;
......
......@@ -255,7 +255,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.setting-drawer-index-content {
......
......@@ -22,7 +22,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.setting-drawer-index-item {
margin-bottom: 24px;
......
......@@ -77,7 +77,7 @@
}
</script>
<style lang="scss">
<style lang="less">
.detail-list {
......
......@@ -15,7 +15,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.toolbar {
position: fixed;
width: 100%;
......
......@@ -30,7 +30,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.head-info {
position: relative;
text-align: left;
......
......@@ -324,7 +324,7 @@
top: 50px !important;
}
</style>
<style lang="scss" scoped>
<style lang="less" scoped>
.header-notice{
display: inline-block;
transition: all 0.3s;
......
......@@ -80,7 +80,7 @@ export default {
}
};
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.step-form-wrapper {
margin: 0 auto;
width: 80%;
......
......@@ -221,25 +221,21 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
/* update_begin author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
/* update-begin author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
.user-wrapper .search-input {
width: 180px;
color: inherit;
/deep/ {
.ant-select-selection {
/deep/ .ant-select-selection {
background-color: inherit;
border: 0;
border-bottom: 1px solid white;
&__placeholder, &__field__placeholder {
color: inherit;
}
}
.ant-select-selection__placeholder,
.ant-select-search__field__placeholder {
color: inherit;
}
}
}
/* update-end author:sunjianlei date:20191220 for: 解决全局样式冲突问题 */
/* update_end author:zhaoxin date:20191129 for: 让搜索框颜色能随主题颜色变换*/
......
......@@ -18,8 +18,12 @@ import VueApexCharts from 'vue-apexcharts'
import preview from 'vue-photo-preview'
import 'vue-photo-preview/dist/skin.css'
import "@jeecg/antd-online-214"
import '@jeecg/antd-online-214/dist/OnlineForm.css'
// import "@jeecg/antd-online-214"
// import '@jeecg/antd-online-214/dist/OnlineForm.css'
if (process.env.NODE_ENV !== 'production') {
require('@jeecg/antd-online-214')
require('@jeecg/antd-online-214/dist/OnlineForm.css')
}
import {
ACCESS_TOKEN,
......
......@@ -180,7 +180,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.page-header-wrapper-grid-content-main {
width: 100%;
height: 100%;
......
......@@ -79,7 +79,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.app-list {
......
......@@ -83,7 +83,7 @@
};
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.avatar-upload-preview {
position: absolute;
......
......@@ -103,7 +103,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.avatar-upload-wrapper {
height: 200px;
......
......@@ -106,7 +106,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.account-settings-info-main {
width: 100%;
display: flex;
......
......@@ -446,7 +446,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.extra-wrapper {
line-height: 55px;
padding-right: 24px;
......
......@@ -218,7 +218,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.circle-cust{
position: relative;
top: 28px;
......
......@@ -245,7 +245,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.project-list {
.card-title {
......
......@@ -37,7 +37,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.exception {
min-height: 500px;
height: 80%;
......
......@@ -199,7 +199,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.card{
margin-bottom: 24px;
}
......
......@@ -69,7 +69,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.stepFormText {
margin-bottom: 24px;
......
......@@ -52,7 +52,7 @@
}
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.information {
line-height: 22px;
......
......@@ -54,7 +54,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.steps {
max-width: 750px;
margin: 16px auto;
......
......@@ -630,7 +630,7 @@
}
</script>
<style lang="scss">
<style lang="less">
.card-container {
background: #fff;
overflow: hidden;
......@@ -678,7 +678,7 @@
}
}
</style>
<style lang="scss" scoped>
<style lang="less" scoped>
.container-widthEn{
width: 755px;
}
......
......@@ -625,7 +625,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.extra-wrapper {
line-height: 55px;
padding-right: 24px;
......
......@@ -59,7 +59,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.card-avatar {
width: 48px;
height: 48px;
......
......@@ -139,7 +139,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.ant-avatar-lg {
width: 48px;
height: 48px;
......
......@@ -248,7 +248,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.search {
margin-bottom: 54px;
}
......
......@@ -63,7 +63,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.search-head{
background-color: #fff;
margin: -25px -24px -24px;
......
/**
* online 自定义按钮表达式处理类
*/
export default class ButtonExpHandler {
/**
* 构造器
* @param express
*/
constructor(express,record) {
this._express = express;
this._record = record;
}
get show() {
if(!this._express || this._express==''){
return true;
}
let arr = this._express.split('#');
//获取字段值
let fieldValue = this._record[arr[0]];
//获取表达式
let exp = arr[1].toLowerCase();
//判断表达式
if(exp === 'eq'){
return fieldValue == arr[2];
}else if(exp === 'ne'){
return !(fieldValue == arr[2]);
}else if(exp === 'empty'){
if(arr[2]==='true' || arr[2]===true){
return !fieldValue || fieldValue=='';
}else{
return fieldValue && fieldValue.length>0
}
}else if(exp === 'in'){
let arr2 = arr[2].split(',');
return arr2.indexOf(String(fieldValue))>=0;
}
return false;
}
}
\ No newline at end of file
......@@ -209,6 +209,7 @@
import { cloneObject, filterObj } from '@/utils/util'
import JImportModal from '@/components/jeecg/JImportModal'
import JSuperQuery from '@comp/jeecg/JSuperQuery'
import ButtonExpHandler from './ButtonExpHandler'
export default {
name: 'OnlCgFormAutoList',
......
......@@ -300,7 +300,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.detail-layout {
margin-left: 44px;
......
......@@ -245,7 +245,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.title {
color: rgba(0,0,0,.85);
font-size: 16px;
......
......@@ -39,7 +39,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.result {
text-align: center;
width: 72%;
......
......@@ -201,7 +201,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.drawer-bootom-button {
position: absolute;
bottom: 0;
......
......@@ -376,4 +376,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -55,4 +55,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -224,4 +224,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -188,4 +188,4 @@
}
</script>
<style lang="scss" scoped></style>
\ No newline at end of file
<style lang="less" scoped></style>
\ No newline at end of file
......@@ -184,7 +184,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.drawer-bootom-button {
position: absolute;
bottom: 0;
......
......@@ -60,7 +60,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.steps {
max-width: 750px;
margin: 16px auto;
......
......@@ -486,7 +486,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.user-layout-login {
label {
......
......@@ -318,7 +318,7 @@
}
}
</script>
<style lang="scss">
<style lang="less">
.user-register {
&.error {
......@@ -341,7 +341,7 @@
}
}
</style>
<style lang="scss" scoped>
<style lang="less" scoped>
.user-layout-register {
& > h3 {
......
......@@ -184,7 +184,7 @@
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.stepFormText {
margin-bottom: 24px;
}
......
......@@ -119,7 +119,7 @@
}
}
</script>
<style lang="scss" scoped>
<style lang="less" scoped>
.stepFormText {
margin-bottom: 24px;
}
......
const path = require('path')
function resolve(dir) {
function resolve (dir) {
return path.join(__dirname, dir)
}
......@@ -14,10 +14,10 @@ module.exports = {
// 如果你不需要生产环境的 source map,可以将其设置为 false 以加速生产环境构建。
productionSourceMap: false,
//打包app时放开该配置
//publicPath:'./',
// 打包app时放开该配置
// publicPath:'./',
configureWebpack: config => {
//生产环境取消 console.log
// 生产环境取消 console.log
if (process.env.NODE_ENV === 'production') {
config.optimization.minimizer[0].options.terserOptions.compress.drop_console = true
}
......@@ -47,9 +47,9 @@ module.exports = {
/* less 变量覆盖,用于自定义 ant design 主题 */
'primary-color': '#1890FF',
'link-color': '#1890FF',
'border-radius-base': '4px',
'border-radius-base': '4px'
},
javascriptEnabled: true,
javascriptEnabled: true
}
}
},
......@@ -57,21 +57,21 @@ module.exports = {
devServer: {
port: 3000,
proxy: {
/* '/api': {
/* '/api': {
target: 'https://mock.ihx.me/mock/5baf3052f7da7e07e04a5116/antd-pro', //mock API接口系统
ws: false,
changeOrigin: true,
pathRewrite: {
'/jeecg-boot': '' //默认所有请求都加了jeecg-boot前缀,需要去掉
}
},*/
}, */
'/jeecg-boot': {
target: 'http://localhost:8080', //请求本地 需要jeecg-boot后台项目
target: 'http://127.0.0.1:8080', // 请求本地 需要jeecg-boot后台项目
ws: false,
changeOrigin: true
},
}
}
},
lintOnSave: undefined
}
\ No newline at end of file
}
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册