Commit 237fd13d5841dceab6c0bb14f012ad4a2495d73b
1 parent
1ea22c3f
1、添加表格自动换行
2添加表格列字体对其方式特殊属性 3添加折线图滑块默认100%
Showing
9 changed files
with
86 additions
and
21 deletions
config/dev.env.js
| @@ -5,7 +5,7 @@ const prodEnv = require('./prod.env') | @@ -5,7 +5,7 @@ const prodEnv = require('./prod.env') | ||
| 5 | const isDev = false; | 5 | const isDev = false; |
| 6 | //开发API地址 | 6 | //开发API地址 |
| 7 | // const devAdrress='"http://weberp.xlyprint.cn/xlyReport"'; | 7 | // const devAdrress='"http://weberp.xlyprint.cn/xlyReport"'; |
| 8 | -const devAdrress='"http://127.0.0.1:8080/xlyReport"'; | 8 | +const devAdrress='"http://172.16.114.9:8085/xlyReport"'; |
| 9 | //正式打包API地址 | 9 | //正式打包API地址 |
| 10 | const ipAdrress='"http://"+location.host+"/xlyReport"'; | 10 | const ipAdrress='"http://"+location.host+"/xlyReport"'; |
| 11 | 11 |
src/mixins/queryform.js
| @@ -178,8 +178,6 @@ export default { | @@ -178,8 +178,6 @@ export default { | ||
| 178 | const value = chartProperties[key]; | 178 | const value = chartProperties[key]; |
| 179 | obj["type"] = value; | 179 | obj["type"] = value; |
| 180 | obj["name"] = key; | 180 | obj["name"] = key; |
| 181 | - console.log("3333333",value,key); | ||
| 182 | - console.log("22222222",chartProperties,data); | ||
| 183 | for (let i = 0; i < data.length; i++) { | 181 | for (let i = 0; i < data.length; i++) { |
| 184 | if (value.startsWith("xAxis")) { | 182 | if (value.startsWith("xAxis")) { |
| 185 | // 代表为x轴 | 183 | // 代表为x轴 |
| @@ -216,7 +214,7 @@ export default { | @@ -216,7 +214,7 @@ export default { | ||
| 216 | const value = chartProperties[key]; | 214 | const value = chartProperties[key]; |
| 217 | obj["type"] = value; | 215 | obj["type"] = value; |
| 218 | obj["name"] = key; | 216 | obj["name"] = key; |
| 219 | - console.log("value",value); | 217 | + // console.log("value",value); |
| 220 | if(value=='xAxis' || value=='bar'|| value=='line'){ | 218 | if(value=='xAxis' || value=='bar'|| value=='line'){ |
| 221 | for (let i = 0; i < data.length; i++) { | 219 | for (let i = 0; i < data.length; i++) { |
| 222 | if (value.startsWith("xAxis")) { | 220 | if (value.startsWith("xAxis")) { |
src/views/bigscreenDesigner/designer/components/dynamicAddTable.vue
| @@ -12,6 +12,7 @@ | @@ -12,6 +12,7 @@ | ||
| 12 | <el-table-column prop="name" label="名称" width="60" /> | 12 | <el-table-column prop="name" label="名称" width="60" /> |
| 13 | <el-table-column prop="key" label="key值" width="70" /> | 13 | <el-table-column prop="key" label="key值" width="70" /> |
| 14 | <el-table-column prop="width" label="宽度" width="50" /> | 14 | <el-table-column prop="width" label="宽度" width="50" /> |
| 15 | + <el-table-column prop="textAlignCol" label="对齐" width="50" /> | ||
| 15 | <el-table-column label="操作" width="100"> | 16 | <el-table-column label="操作" width="100"> |
| 16 | <template slot-scope="scope"> | 17 | <template slot-scope="scope"> |
| 17 | <div class="button-group"> | 18 | <div class="button-group"> |
| @@ -63,6 +64,19 @@ | @@ -63,6 +64,19 @@ | ||
| 63 | > | 64 | > |
| 64 | </el-input> | 65 | </el-input> |
| 65 | </el-form-item> | 66 | </el-form-item> |
| 67 | + <el-form-item label="对齐:"> | ||
| 68 | + <el-select | ||
| 69 | + v-model.trim="rowFormData['textAlignCol']" | ||
| 70 | + placeholder="请选择" | ||
| 71 | + size="mini" | ||
| 72 | + > | ||
| 73 | + <el-option label="无" value="none"></el-option> | ||
| 74 | + <el-option label="居中" value="center"></el-option> | ||
| 75 | + <el-option label="左对齐" value="left"></el-option> | ||
| 76 | + <el-option label="右对齐" value="right"></el-option> | ||
| 77 | + <el-option label="两端对齐" value="justify"></el-option> | ||
| 78 | + </el-select> | ||
| 79 | + </el-form-item> | ||
| 66 | </el-form> | 80 | </el-form> |
| 67 | <span slot="footer" class="dialog-footer"> | 81 | <span slot="footer" class="dialog-footer"> |
| 68 | <el-button size="mini" @click="dialogVisible = false">取 消</el-button> | 82 | <el-button size="mini" @click="dialogVisible = false">取 消</el-button> |
| @@ -89,7 +103,8 @@ export default { | @@ -89,7 +103,8 @@ export default { | ||
| 89 | rowFormData: { | 103 | rowFormData: { |
| 90 | name: "", | 104 | name: "", |
| 91 | key: "", | 105 | key: "", |
| 92 | - width: "" | 106 | + width: "", |
| 107 | + textAlignCol: "" | ||
| 93 | }, | 108 | }, |
| 94 | flag: true, // true 新增, false 编辑 | 109 | flag: true, // true 新增, false 编辑 |
| 95 | indexEditor: -1, // 编辑第几个数据 | 110 | indexEditor: -1, // 编辑第几个数据 |
src/views/bigscreenDesigner/designer/tools/configure/lineCharts/widget-linechart.js
| @@ -596,7 +596,7 @@ export const widgetLinechart = { | @@ -596,7 +596,7 @@ export const widgetLinechart = { | ||
| 596 | name: 'startZoom', | 596 | name: 'startZoom', |
| 597 | required: false, | 597 | required: false, |
| 598 | placeholder: '', | 598 | placeholder: '', |
| 599 | - value: 80, | 599 | + value: 0, |
| 600 | }, | 600 | }, |
| 601 | { | 601 | { |
| 602 | type: 'el-slider', | 602 | type: 'el-slider', |
src/views/bigscreenDesigner/designer/tools/configure/table/widget-table.js
| @@ -63,6 +63,14 @@ export const widgetTable = { | @@ -63,6 +63,14 @@ export const widgetTable = { | ||
| 63 | value: true | 63 | value: true |
| 64 | }, | 64 | }, |
| 65 | { | 65 | { |
| 66 | + type: 'el-switch', | ||
| 67 | + label: '是否自动换行', | ||
| 68 | + name: 'bAutoHeight', | ||
| 69 | + required: false, | ||
| 70 | + placeholder: '', | ||
| 71 | + value: true | ||
| 72 | + }, | ||
| 73 | + { | ||
| 66 | type: 'el-select', | 74 | type: 'el-select', |
| 67 | label: '动画效果', | 75 | label: '动画效果', |
| 68 | name: 'effect', | 76 | name: 'effect', |
src/views/bigscreenDesigner/designer/widget/div/widgetDtImage.vue
| @@ -108,10 +108,15 @@ export default { | @@ -108,10 +108,15 @@ export default { | ||
| 108 | } | 108 | } |
| 109 | }, | 109 | }, |
| 110 | getEchartData() { | 110 | getEchartData() { |
| 111 | - this.imageAdress=this.getShowPic(); | 111 | + const imageAdressOld =this.imageAdress; |
| 112 | + const imageAdressNew =this.getShowPic(); | ||
| 113 | + //this.imageAdress = this.getShowPic(); | ||
| 112 | this.imageAdressShow = this.isNotBlank(this.imageAdress); | 114 | this.imageAdressShow = this.isNotBlank(this.imageAdress); |
| 113 | - // console.log("this.imageAdress",this.imageAdress, this.imageAdressShow) | ||
| 114 | - this.reload(); | 115 | + // console.log("this.imageAdress",imageAdressOld, imageAdressNew,(imageAdressOld!==imageAdressNew) ) |
| 116 | + if(imageAdressOld!==imageAdressNew){ | ||
| 117 | + this.imageAdress = imageAdressNew; | ||
| 118 | + this.reload(); | ||
| 119 | + } | ||
| 115 | }, | 120 | }, |
| 116 | getShowPic() { | 121 | getShowPic() { |
| 117 | const {textPic, slectedDataType} = this.transStyle; | 122 | const {textPic, slectedDataType} = this.transStyle; |
src/views/bigscreenDesigner/designer/widget/div/widgetHtmlSlider.vue
| @@ -100,7 +100,7 @@ export default { | @@ -100,7 +100,7 @@ export default { | ||
| 100 | urlData[i] = url; | 100 | urlData[i] = url; |
| 101 | } | 101 | } |
| 102 | } | 102 | } |
| 103 | - console.log("12",urlData); | 103 | + // console.log("12",urlData); |
| 104 | this.urlData = urlData; | 104 | this.urlData = urlData; |
| 105 | this.urlData={...this.urlData}; | 105 | this.urlData={...this.urlData}; |
| 106 | }, | 106 | }, |
src/views/bigscreenDesigner/designer/widget/table/widgetTable.vue
| @@ -20,11 +20,12 @@ | @@ -20,11 +20,12 @@ | ||
| 20 | :key="index" | 20 | :key="index" |
| 21 | :style="tableRowHeight()" | 21 | :style="tableRowHeight()" |
| 22 | > | 22 | > |
| 23 | + <!-- class="contentStyle"--> | ||
| 23 | <div | 24 | <div |
| 24 | - class="content" | ||
| 25 | v-for="(itemChild, idx) in header" | 25 | v-for="(itemChild, idx) in header" |
| 26 | :key="idx" | 26 | :key="idx" |
| 27 | :style="[ | 27 | :style="[ |
| 28 | + contentStyle(), | ||
| 28 | bodyTableStyle, | 29 | bodyTableStyle, |
| 29 | bodyTable(index), | 30 | bodyTable(index), |
| 30 | tableFiledWidth(idx), | 31 | tableFiledWidth(idx), |
| @@ -59,13 +60,15 @@ export default { | @@ -59,13 +60,15 @@ export default { | ||
| 59 | autoPage: true, | 60 | autoPage: true, |
| 60 | //effect: "top", | 61 | //effect: "top", |
| 61 | autoPlay: true, | 62 | autoPlay: true, |
| 63 | + bAutoHeight: true, | ||
| 62 | vis: 5, | 64 | vis: 5, |
| 63 | - rowHeight: "50px" | 65 | + rowHeight: "50px", |
| 64 | }, | 66 | }, |
| 65 | header: [], | 67 | header: [], |
| 66 | list: [], | 68 | list: [], |
| 67 | optionsSetUp: {}, | 69 | optionsSetUp: {}, |
| 68 | optionsPosition: {}, | 70 | optionsPosition: {}, |
| 71 | + // contentStyle:{}, | ||
| 69 | optionsData: {} | 72 | optionsData: {} |
| 70 | }; | 73 | }; |
| 71 | }, | 74 | }, |
| @@ -146,6 +149,19 @@ export default { | @@ -146,6 +149,19 @@ export default { | ||
| 146 | this.options = options; | 149 | this.options = options; |
| 147 | this.hackResetFun(); | 150 | this.hackResetFun(); |
| 148 | }, | 151 | }, |
| 152 | + contentStyle(){ | ||
| 153 | + let styleJson={}; | ||
| 154 | + const rollSet = this.optionsSetUp; | ||
| 155 | + if(!rollSet.bAutoHeight){ | ||
| 156 | + styleJson["white-space"]="nowrap"; | ||
| 157 | + styleJson["overflow"]="nowrap"; | ||
| 158 | + styleJson["text-overflow"]="ellipsis"; | ||
| 159 | + styleJson["overflow-wrap"]=""; | ||
| 160 | + }else{ | ||
| 161 | + styleJson["overflow-wrap"]="break-word"; | ||
| 162 | + } | ||
| 163 | + return styleJson; | ||
| 164 | + }, | ||
| 149 | handlerHead() { | 165 | handlerHead() { |
| 150 | const head = this.optionsSetUp.dynamicAddTable; | 166 | const head = this.optionsSetUp.dynamicAddTable; |
| 151 | this.header = head; | 167 | this.header = head; |
| @@ -196,12 +212,18 @@ export default { | @@ -196,12 +212,18 @@ export default { | ||
| 196 | }, | 212 | }, |
| 197 | tableRowHeight() { | 213 | tableRowHeight() { |
| 198 | let styleJson = {}; | 214 | let styleJson = {}; |
| 199 | - if (this.optionsSetUp.rowHeight) { | ||
| 200 | - styleJson["height"] = this.optionsSetUp.rowHeight + "px"; | ||
| 201 | - styleJson["line-height"] = this.optionsSetUp.rowHeight + "px"; | ||
| 202 | - } else { | ||
| 203 | - styleJson["height"] = this.options.rowHeight; | ||
| 204 | - styleJson["line-height"] = this.optionsSetUp.rowHeight + "px"; | 215 | + const bAutoHeight = this.optionsSetUp.bAutoHeight; |
| 216 | + if(!bAutoHeight){ | ||
| 217 | + if (this.optionsSetUp.rowHeight) { | ||
| 218 | + styleJson["height"] = this.optionsSetUp.rowHeight + "px"; | ||
| 219 | + styleJson["line-height"] = this.optionsSetUp.rowHeight + "px"; | ||
| 220 | + } else { | ||
| 221 | + styleJson["height"] = this.options.rowHeight; | ||
| 222 | + styleJson["line-height"] = this.optionsSetUp.rowHeight + "px"; | ||
| 223 | + } | ||
| 224 | + }else{ | ||
| 225 | + styleJson["height"] = "auto"; | ||
| 226 | + styleJson["line-height"]=this.optionsSetUp.rowHeight+ "px"; | ||
| 205 | } | 227 | } |
| 206 | return styleJson; | 228 | return styleJson; |
| 207 | }, | 229 | }, |
| @@ -210,6 +232,9 @@ export default { | @@ -210,6 +232,9 @@ export default { | ||
| 210 | if (this.optionsSetUp.dynamicAddTable[index].width) { | 232 | if (this.optionsSetUp.dynamicAddTable[index].width) { |
| 211 | styleJson["width"] = this.optionsSetUp.dynamicAddTable[index].width; | 233 | styleJson["width"] = this.optionsSetUp.dynamicAddTable[index].width; |
| 212 | } | 234 | } |
| 235 | + if (this.optionsSetUp.dynamicAddTable[index].textAlignCol) { | ||
| 236 | + styleJson["text-align"] = this.optionsSetUp.dynamicAddTable[index].textAlignCol; | ||
| 237 | + } | ||
| 213 | return styleJson; | 238 | return styleJson; |
| 214 | } | 239 | } |
| 215 | } | 240 | } |
| @@ -239,8 +264,8 @@ export default { | @@ -239,8 +264,8 @@ export default { | ||
| 239 | } | 264 | } |
| 240 | 265 | ||
| 241 | .txtScroll-top .infoList li { | 266 | .txtScroll-top .infoList li { |
| 242 | - height: 50px; | ||
| 243 | - line-height: 50px; | 267 | + //height: 50px; |
| 268 | + //line-height: 50px; | ||
| 244 | display: flex; | 269 | display: flex; |
| 245 | flex-direction: row; | 270 | flex-direction: row; |
| 246 | } | 271 | } |
src/views/screenDesigner/components/dynamicAddTable.vue
| @@ -12,6 +12,7 @@ | @@ -12,6 +12,7 @@ | ||
| 12 | <el-table-column prop="name" label="名称" width="60" /> | 12 | <el-table-column prop="name" label="名称" width="60" /> |
| 13 | <el-table-column prop="key" label="key值" width="70" /> | 13 | <el-table-column prop="key" label="key值" width="70" /> |
| 14 | <el-table-column prop="width" label="宽度" width="50" /> | 14 | <el-table-column prop="width" label="宽度" width="50" /> |
| 15 | + <el-table-column prop="textAlignCol" label="对齐" width="50" /> | ||
| 15 | <el-table-column label="操作" width="100"> | 16 | <el-table-column label="操作" width="100"> |
| 16 | <template slot-scope="scope"> | 17 | <template slot-scope="scope"> |
| 17 | <div class="button-group"> | 18 | <div class="button-group"> |
| @@ -63,6 +64,18 @@ | @@ -63,6 +64,18 @@ | ||
| 63 | > | 64 | > |
| 64 | </el-input> | 65 | </el-input> |
| 65 | </el-form-item> | 66 | </el-form-item> |
| 67 | + <el-form-item label="对齐方式:"> | ||
| 68 | + <el-select | ||
| 69 | + v-model.trim="rowFormData['textAlignCol']" | ||
| 70 | + placeholder="请选择" | ||
| 71 | + > | ||
| 72 | + <el-option label="无" value="none"></el-option> | ||
| 73 | + <el-option label="居中" value="center"></el-option> | ||
| 74 | + <el-option label="左对齐" value="left"></el-option> | ||
| 75 | + <el-option label="右对齐" value="right"></el-option> | ||
| 76 | + <el-option label="两端对齐" value="justify"></el-option> | ||
| 77 | + </el-select> | ||
| 78 | + </el-form-item> | ||
| 66 | </el-form> | 79 | </el-form> |
| 67 | <span slot="footer" class="dialog-footer"> | 80 | <span slot="footer" class="dialog-footer"> |
| 68 | <el-button size="mini" @click="dialogVisible = false">取 消</el-button> | 81 | <el-button size="mini" @click="dialogVisible = false">取 消</el-button> |
| @@ -88,7 +101,8 @@ export default { | @@ -88,7 +101,8 @@ export default { | ||
| 88 | rowFormData: { | 101 | rowFormData: { |
| 89 | name: "", | 102 | name: "", |
| 90 | key: "", | 103 | key: "", |
| 91 | - width: "" | 104 | + width: "", |
| 105 | + textAlignCol: "" | ||
| 92 | }, | 106 | }, |
| 93 | flag: true, // true 新增, false 编辑 | 107 | flag: true, // true 新增, false 编辑 |
| 94 | indexEditor: -1, // 编辑第几个数据 | 108 | indexEditor: -1, // 编辑第几个数据 |