Преглед изворни кода

Merge remote-tracking branch 'origin/master'

yuhan пре 1 година
родитељ
комит
42ab8ee729

+ 2 - 0
public/index.html

@@ -12,6 +12,8 @@
   <!-- <link rel="shortcut icon" href="<%= BASE_URL %>favicon.ico" type="image/x-icon"> -->
   <link rel="icon" href="<%= BASE_URL %>logo.png">
   <script src="<%= BASE_URL %>cdn/babel-polyfill/polyfill_7_2_5.js"></script>
+  <!-- <script type="text/javascript" src="//api.map.baidu.com/api?type=webgl&v=1.0&ak=z5soY0FNGbDJK7LBzfBstOyF92yB03ft"></script> -->
+  <script type="text/javascript" src="//api.map.baidu.com/api?v=1.1&ak=z5soY0FNGbDJK7LBzfBstOyF92yB03ft"></script>
   <style>
     html,
     body,

BIN
src/assets/societyTree_light.png


+ 7 - 0
src/main.js

@@ -53,6 +53,9 @@ import '@/components/jeecg/JVxeTable/install'
 import '@/components/JVxeCells/install'
 //表单验证
 import { rules } from '@/utils/rules'
+
+import BaiduMap from 'vue-baidu-map'
+
 Vue.prototype.rules = rules
 Vue.config.productionTip = false
 // 修改框架:全局挂载方法递归树
@@ -71,6 +74,10 @@ Vue.use(JeecgComponents);
 Vue.use(UComponents);
 Vue.use(VueAreaLinkage);
 
+Vue.use(BaiduMap, {
+  ak:'z5soY0FNGbDJK7LBzfBstOyF92yB03ft' 
+})
+
 SSO.init(() => {
   main()
 })

+ 137 - 55
src/views/module_cmms/upkeepPlan/UpkeepPlanList.vue

@@ -4,6 +4,47 @@
     <div class="table-page-search-wrapper">
       <a-form layout="inline" @keyup.enter.native="searchQuery">
         <a-row :gutter="24">
+          <a-col :xl="6" :lg="7" :md="8" :sm="24">
+            <a-form-item label="计划编号">
+              <a-input placeholder="请输入计划名称" v-model="queryParam.plancode"></a-input>
+            </a-form-item>
+          </a-col>
+          <a-col :xl="6" :lg="7" :md="8" :sm="24">
+            <a-form-item label="计划名称">
+              <a-input placeholder="请输入计划名称" v-model="queryParam.planname"></a-input>
+            </a-form-item>
+          </a-col>
+          <!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">
+            <a-form-item label="设备类型">
+              <j-tree-select
+                ref="treeSelect"
+                placeholder="请选择设备类型"
+                v-model="queryParam.equipdefid"
+                dict="tpm_equipment_tree,name,id"
+                pidField="parentid"
+                pidValue="0"
+                hasChildField="has_child"
+                >
+              </j-tree-select>
+            </a-form-item>
+          </a-col> -->
+          <template v-if="toggleSearchStatus">
+            <a-col :xl="6" :lg="7" :md="8" :sm="24">
+              <a-form-item label="保养项编号">
+                <a-input placeholder="请输入保养项编号" v-model="queryParam.itemcode"></a-input>
+              </a-form-item>
+            </a-col>
+          </template>
+          <a-col :xl="6" :lg="7" :md="8" :sm="24">
+            <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
+              <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
+              <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
+              <a @click="handleToggleSearch" style="margin-left: 8px">
+                {{ toggleSearchStatus ? '收起' : '展开' }}
+                <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
+              </a>
+            </span>
+          </a-col>
         </a-row>
       </a-form>
     </div>
@@ -47,6 +88,10 @@
         class="j-table-force-nowrap"
         @change="handleTableChange">
 
+        <template slot="status"  slot-scope="text, record">
+          <a-switch :checked= "record.status == 0 ? true : false" @click="statusChange(record,$event)" />
+        </template>
+
         <template slot="htmlSlot" slot-scope="text">
           <div v-html="text"></div>
         </template>
@@ -98,6 +143,7 @@
   import '@/assets/less/TableExpand.less'
   import { mixinDevice } from '@/utils/mixin'
   import { JeecgListMixin } from '@/mixins/JeecgListMixin'
+  import { httpAction, getAction } from '@/api/manage'
   import UpkeepPlanModal from './modules/UpkeepPlanModal'
 
   export default {
@@ -122,120 +168,122 @@
             }
           },
           {
-            title:'保养计划编号',
+            title:'计划编号',
             align:"center",
             dataIndex: 'plancode'
           },
           {
-            title:'保养计划名称',
+            title:'计划名称',
             align:"center",
             dataIndex: 'planname'
           },
+          {
+            title:'设备',
+            align:"center",
+            dataIndex: 'equipmentName'
+          },
           // {
           //   title:'保养工作项目ID',
           //   align:"center",
           //   dataIndex: 'upkeepprojid'
           // },
-          {
-            title:'工作项目名称',
-            align:"center",
-            dataIndex: 'projectname'
-          },
+          // {
+          //   title:'工作项目名称',
+          //   align:"center",
+          //   dataIndex: 'projectname'
+          // },
           {
             title:'地点',
             align:"center",
             dataIndex: 'address'
           },
-          {
-            title:'厂商名称',
-            align:"center",
-            dataIndex: 'supplier'
-          },
-          {
-            title:'厂商电话',
-            align:"center",
-            dataIndex: 'suppliertel'
-          },
-          {
-            title:'联系人',
-            align:"center",
-            dataIndex: 'linker'
-          },
-          {
-            title:'联系人电话',
-            align:"center",
-            dataIndex: 'linkertel'
-          },
+          // {
+          //   title:'厂商名称',
+          //   align:"center",
+          //   dataIndex: 'supplier'
+          // },
+          // {
+          //   title:'厂商电话',
+          //   align:"center",
+          //   dataIndex: 'suppliertel'
+          // },
+          // {
+          //   title:'联系人',
+          //   align:"center",
+          //   dataIndex: 'linker'
+          // },
+          // {
+          //   title:'联系人电话',
+          //   align:"center",
+          //   dataIndex: 'linkertel'
+          // },
           {
             title:'负责人',
             align:"center",
-            dataIndex: 'chargeruser'
-          },
-          {
-            title:'描述',
-            align:"center",
-            dataIndex: 'plandesc'
+            dataIndex: 'chargeruser_dictText'
           },
+          // {
+          //   title:'描述',
+          //   align:"center",
+          //   dataIndex: 'plandesc'
+          // },
           {
             title:'开始时间',
             align:"center",
             dataIndex: 'begintime',
-            customRender:function (text) {
-              return !text?"":(text.length>10?text.substr(0,10):text)
-            }
+            // customRender:function (text) {
+            //   return !text?"":(text.length>10?text.substr(0,10):text)
+            // }
           },
           {
-            title:'重复',
+            title:'重复间隔',
             align:"center",
             dataIndex: 'repeatnum'
           },
           {
-            title:'重复类型:年、月、周、日、时、分',
+            title:'间隔单位',
             align:"center",
             dataIndex: 'repeattype'
           },
           {
-            title:'提前通知时',
+            title:'提前通知时',
             align:"center",
             dataIndex: 'noticenum'
           },
           {
-            title:'提前通知类型:天、时、分',
+            title:'时长单位',
             align:"center",
             dataIndex: 'noticetype'
           },
+          // 状态(0启用 1停用)
           {
-            title:'状态(0启用 1停用)',
+            title:'状态',
             align:"center",
-            dataIndex: 'status'
+            dataIndex: 'status',
+            scopedSlots: { customRender: 'status' }
           },
           {
             title:'下次执行时间',
             align:"center",
             dataIndex: 'nexttime',
-            customRender:function (text) {
-              return !text?"":(text.length>10?text.substr(0,10):text)
-            }
+            // customRender:function (text) {
+            //   return !text?"":(text.length>10?text.substr(0,10):text)
+            // }
           },
           {
             title:'下次通知时间',
             align:"center",
             dataIndex: 'noticetime',
-            customRender:function (text) {
-              return !text?"":(text.length>10?text.substr(0,10):text)
-            }
+            // customRender:function (text) {
+            //   return !text?"":(text.length>10?text.substr(0,10):text)
+            // }
           },
           {
-            title:'是否已通知:是/否',
+            title:'通知状态',
             align:"center",
             dataIndex: 'ifnotice'
           },
           {
-            title:'设备id(根据设备id查找保养项内容)',
-            align:"center",
-            dataIndex: 'equipmentid'
-          },
-          {
             title:'备注',
             align:"center",
             dataIndex: 'remark'
@@ -255,10 +303,11 @@
           deleteBatch: "/cmmsUpkeepPlan/cmmsUpkeepPlan/deleteBatch",
           exportXlsUrl: "/cmmsUpkeepPlan/cmmsUpkeepPlan/exportXls",
           importExcelUrl: "cmmsUpkeepPlan/cmmsUpkeepPlan/importExcel",
-          
+          edit: "/cmmsUpkeepPlan/cmmsUpkeepPlan/updateCmmsUpkeepPlanStatusById",
         },
         dictOptions:{},
         superFieldList:[],
+        model: {}
       }
     },
     created() {
@@ -297,6 +346,39 @@
         fieldList.push({type:'string',value:'ifnotice',text:'是否已通知:是/否',dictCode:''})
         fieldList.push({type:'string',value:'equipmentid',text:'设备id(根据设备id查找保养项内容)',dictCode:''})
         this.superFieldList = fieldList
+      },
+      statusChange(record,$event){
+        console.log(record.status,$event)
+        let text1 = record.status === "0" ? "是否确认停用“" : "是否确认使用“";
+        let text2 = record.status === "0" ? "”,请确保该设备有可使用的保养计划" : "”,若启用当前保养计划则该设备其他保养计划默认禁用";
+        const that = this
+        that.$confirm({
+          title: "提示",
+          content: text1 + record.planname + text2,
+          onOk() {
+            let httpurl = '';
+            let method = 'put';
+            httpurl+=that.url.edit;
+            if (record.status == 1) {
+              that.model.id = record.id
+              that.model.status = 0
+            } else {
+              that.model.id = record.id
+              that.model.status = 1
+            }
+            httpAction(httpurl,that.model,method).then((res)=>{
+              if(res.success){
+                that.$message.success(res.message);
+                that.modalFormOk()
+              }else{
+                that.$message.warning(res.message);
+              }
+            })
+          },
+          onCancel() {
+            // that.modalFormOk()
+          }
+        });
       }
     }
   }

+ 260 - 119
src/views/module_cmms/upkeepPlan/modules/UpkeepPlanForm.vue

@@ -2,118 +2,149 @@
   <a-spin :spinning="confirmLoading">
     <j-form-container :disabled="formDisabled">
       <a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail">
-        <a-row>
-          <a-col :span="12">
-            <a-form-model-item label="保养计划编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="plancode">
-              <a-input v-model="model.plancode" placeholder="请输入保养计划编号"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="保养计划名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="planname">
-              <a-input v-model="model.planname" placeholder="请输入保养计划名称"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="保养工作项目ID" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="upkeepprojid">
-              <a-input v-model="model.upkeepprojid" placeholder="请输入保养工作项目ID"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="工作项目名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="projectname">
-              <a-input v-model="model.projectname" placeholder="请输入工作项目名称"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="地点" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="address">
-              <a-input v-model="model.address" placeholder="请输入地点"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="厂商名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplier">
-              <a-input v-model="model.supplier" placeholder="请输入厂商名称"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="厂商电话" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="suppliertel">
-              <a-input v-model="model.suppliertel" placeholder="请输入厂商电话"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="联系人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="linker">
-              <a-input v-model="model.linker" placeholder="请输入联系人"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="联系人电话" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="linkertel">
-              <a-input v-model="model.linkertel" placeholder="请输入联系人电话"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="负责人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="chargeruser">
-              <a-input v-model="model.chargeruser" placeholder="请输入负责人"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="plandesc">
-              <a-input v-model="model.plandesc" placeholder="请输入描述"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="开始时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="begintime">
-              <j-date placeholder="请选择开始时间" v-model="model.begintime"  style="width: 100%" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="重复" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="repeatnum">
-              <a-input-number v-model="model.repeatnum" :min="1" placeholder="请输入重复" style="width: 100%" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="重复类型:年、月、周、日、时、分" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="repeattype">
-              <a-input v-model="model.repeattype" placeholder="请输入重复类型:年、月、周、日、时、分"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="提前通知时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticenum">
-              <a-input-number v-model="model.noticenum" :min="1" placeholder="请输入提前通知时间" style="width: 100%" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="提前通知类型:天、时、分" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticetype">
-              <a-input v-model="model.noticetype" placeholder="请输入提前通知类型:天、时、分"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="状态(0启用 1停用)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="status">
-              <a-input v-model="model.status" placeholder="请输入状态(0启用 1停用)"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="下次执行时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="nexttime">
-              <j-date placeholder="请选择下次执行时间" v-model="model.nexttime"  style="width: 100%" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="下次通知时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticetime">
-              <j-date placeholder="请选择下次通知时间" v-model="model.noticetime"  style="width: 100%" />
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="是否已通知:是/否" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ifnotice">
-              <a-input v-model="model.ifnotice" placeholder="请输入是否已通知:是/否"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="设备id(根据设备id查找保养项内容)" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="equipmentid">
-              <a-input v-model="model.equipmentid" placeholder="请输入设备id(根据设备id查找保养项内容)"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-          <a-col :span="12">
-            <a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
-              <a-input v-model="model.remark" placeholder="请输入备注"  ></a-input>
-            </a-form-model-item>
-          </a-col>
-        </a-row>
+        <div class="cmms-dialog-item-title">保养计划基本信息</div>
+        <div style="height: 100%;width:100%;display: flex;">
+          <div style="height: 100%;width:92%;">
+            <a-row>
+              <!-- <a-col :span="12">
+                <a-form-model-item label="保养计划编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="plancode">
+                  <a-input v-model="model.plancode" placeholder="请输入保养计划编号"  ></a-input>
+                </a-form-model-item>
+              </a-col> -->
+              <a-col :span="12">
+                <a-form-model-item label="计划名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="planname">
+                  <a-input v-model="model.planname" placeholder="请输入计划名称"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="选择设备" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="equipmentid">
+                  <j-search-select-tag v-model="model.equipmentid" dict="tpm_equipment,equipmentname,id"  style="width: 100%"/>
+                    <!-- <a-button type="primary" icon="search" /> -->
+                </a-form-model-item>
+              </a-col>
+              <!-- <a-col :span="12">
+                <a-form-model-item label="保养工作项目ID" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="upkeepprojid">
+                  <a-input v-model="model.upkeepprojid" placeholder="请输入保养工作项目ID"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="工作项目名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="projectname">
+                  <a-input v-model="model.projectname" placeholder="请输入工作项目名称"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              
+              <a-col :span="12">
+                <a-form-model-item label="厂商名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="supplier">
+                  <a-input v-model="model.supplier" placeholder="请输入厂商名称"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="厂商电话" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="suppliertel">
+                  <a-input v-model="model.suppliertel" placeholder="请输入厂商电话"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="联系人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="linker">
+                  <a-input v-model="model.linker" placeholder="请输入联系人"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="联系人电话" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="linkertel">
+                  <a-input v-model="model.linkertel" placeholder="请输入联系人电话"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="plandesc">
+                  <a-input v-model="model.plandesc" placeholder="请输入描述"  ></a-input>
+                </a-form-model-item>
+              </a-col> -->
+              <a-col :span="12">
+                <a-form-model-item label="地点" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="address">
+                  <a-input v-model="model.address" placeholder="请输入地点"  ></a-input>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="负责人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="chargeruser">
+                  <j-dict-select-tag v-model="model.chargeruser" placeholder="请输入负责人" dictCode="sys_user,realname,id"/>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="开始时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="begintime">
+                  <j-date placeholder="请选择开始时间" v-model="model.begintime"  style="width: 100%" :show-time="true" date-format="YYYY-MM-DD HH:mm:ss"/>
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="提前通知" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticenum">
+                  <a-input-number v-model="model.noticenum" :min="1" placeholder="请输入提前通知时长" style="width: 40%" />
+                  <j-dict-select-tag v-model="model.noticetype" placeholder="时长单位" dictCode="plan_notice_unit" style="width: 30%"/>
+                </a-form-model-item>
+              </a-col>
+              <!-- <a-col :span="12">
+                <a-form-model-item label="通知单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticetype">
+                  <j-dict-select-tag v-model="model.noticetype" placeholder="请选择通知单位" dictCode="plan_notice_unit"/>
+                </a-form-model-item>
+              </a-col> -->
+              <a-col :span="12">
+                <a-form-model-item label="重复间隔" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="repeatnum">
+                  <a-input-number v-model="model.repeatnum" :min="1" placeholder="请输入重复间隔" style="width: 40%" />
+                  <j-dict-select-tag v-model="model.repeattype" placeholder="间隔单位" dictCode="plan_cycle_unit" style="width: 30%" />
+                </a-form-model-item>
+              </a-col>
+              <!-- <a-col :span="12">
+                <a-form-model-item label="间隔单位" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="repeattype">
+                  <j-dict-select-tag v-model="model.repeattype" placeholder="请选择间隔单位" dictCode="plan_cycle_unit"/>
+                </a-form-model-item>
+              </a-col> -->
+              <!-- <a-col :span="12">
+                <a-form-model-item label="状态" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="status">
+                  <a-input v-model="model.status" placeholder="请输入状态(0启用 1停用)"  ></a-input>
+                </a-form-model-item>
+              </a-col> -->
+              <!-- <a-col :span="12">
+                <a-form-model-item label="下次执行时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="nexttime">
+                  <j-date placeholder="请选择下次执行时间" v-model="model.nexttime"  style="width: 100%" />
+                </a-form-model-item>
+              </a-col>
+              <a-col :span="12">
+                <a-form-model-item label="下次通知时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="noticetime">
+                  <j-date placeholder="请选择下次通知时间" v-model="model.noticetime"  style="width: 100%" />
+                </a-form-model-item>
+              </a-col> -->
+              <!-- <a-col :span="12">
+                <a-form-model-item label="是否已通知:是/否" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="ifnotice">
+                  <a-input v-model="model.ifnotice" placeholder="请输入是否已通知:是/否"  ></a-input>
+                </a-form-model-item>
+              </a-col> -->
+              <a-col :span="12">
+                <a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="remark">
+                  <a-textarea v-model="model.remark" placeholder="请输入备注"  :auto-size="{ minRows: 2, maxRows: 2 }"></a-textarea>
+                </a-form-model-item>
+              </a-col>
+            </a-row>
+          </div>
+          <div style="height: 100%;width:8%;padding-top:0.3%;">
+              <a-button type="primary" icon="search" />
+          </div>
+        </div>
+        <div class="cmms-dialog-item-title u-flex-jab">
+          <div>设备保养设置</div>
+          <div>
+            <a-button @click="handleAddUpkeepItem" type="link" icon="plus">保养项</a-button>
+          </div>
+        </div>
+        <a-table
+          ref="table"
+          size="middle"
+          :scroll="{x:true}"
+          bordered
+          rowKey="id"
+          :columns="columns"
+          :dataSource="model.cmmsUpkeepItemDtoList"
+          :pagination="false"
+          class="j-table-force-nowrap">
+        </a-table>
+
+        <upkeep-plan-modal-add ref="modalForm" @ok="modalFormOk" :modelForm="model" :dataList="model.cmmsUpkeepItemDtoList" @customEvent="handleCustomEvent"></upkeep-plan-modal-add>
       </a-form-model>
     </j-form-container>
   </a-spin>
@@ -123,10 +154,15 @@
 
   import { httpAction, getAction } from '@/api/manage'
   import { validateDuplicateValue } from '@/utils/util'
+  import { mixinDevice } from '@/utils/mixin'
+  import { JeecgListMixin } from '@/mixins/JeecgListMixin'
+  import UpkeepPlanModalAdd from './UpkeepPlanModalAdd.vue'
 
   export default {
     name: 'UpkeepPlanForm',
+    mixins:[JeecgListMixin, mixinDevice],
     components: {
+        UpkeepPlanModalAdd
     },
     props: {
       //表单禁用
@@ -139,23 +175,80 @@
     data () {
       return {
         model:{
-         },
+          noticetype: '天',
+          repeattype: '天',
+          cmmsUpkeepItemDtoList: []
+        },
         labelCol: {
           xs: { span: 24 },
-          sm: { span: 5 },
+          sm: { span: 6 },
         },
         wrapperCol: {
           xs: { span: 24 },
-          sm: { span: 16 },
+          sm: { span: 18 },
         },
         confirmLoading: false,
         validatorRules: {
+          planname: [
+            { required: true, message: '请输入保养计划名称!'},
+          ],
+          equipmentid: [
+            { required: true, message: '请选择设备!'},
+          ],
+          address: [
+            { required: true, message: '请输入地点!'},
+          ],
+          chargeruser: [
+            { required: true, message: '请输入负责人!'},
+          ],
+          begintime: [
+            { required: true, message: '请选择开始时间!'},
+          ],
+          noticenum: [
+            { required: true, message: '请输入提前通知时长!'},
+          ],
+          repeatnum: [
+            { required: true, message: '请输入重复间隔!'},
+          ],
         },
         url: {
+          list: "/cmmsSpotcheckItem/cmmsSpotcheckItem/listbyequipmentid/{equipmentid}",
           add: "/cmmsUpkeepPlan/cmmsUpkeepPlan/add",
           edit: "/cmmsUpkeepPlan/cmmsUpkeepPlan/edit",
           queryById: "/cmmsUpkeepPlan/cmmsUpkeepPlan/queryById"
-        }
+        },
+        columns: [
+          {
+            title:'保养项ID',
+            align:"center",
+            dataIndex: 'id'
+          },
+          {
+            title:'保养项名称',
+            align:"center",
+            dataIndex: 'itemname'
+          },
+          // {
+          //   title:'设备类型',
+          //   align:"center",
+          //   dataIndex: 'equiptypeName'
+          // },
+          {
+            title:'保养项编号',
+            align:"center",
+            dataIndex: 'itemcode'
+          },
+          {
+            title:'保养项标准',
+            align:"center",
+            dataIndex: 'itemcontent'
+          },
+          {
+            title:'备注',
+            align:"center",
+            dataIndex: 'remark'
+          },
+        ],
       }
     },
     computed: {
@@ -169,10 +262,25 @@
     },
     methods: {
       add () {
-        this.edit(this.modelDefault);
+        // this.edit(this.modelDefault);
+        this.model = Object.assign({}, this.modelDefault);
+        this.visible = true;
       },
       edit (record) {
-        this.model = Object.assign({}, record);
+        // this.model = Object.assign({}, record);
+        getAction(this.url.queryById, record).then((res) => {
+            console.log(88,res)
+            this.model = res.result
+            // this.model.cmmsUpkeepItemDtoList = this.model.cmmsUpkeepItemDtoList.map((res) => {
+            //   return {
+            //     id: id,
+            //     itemcode: res.itemcode,
+            //     itemname: res.itemname,
+            //     itemcontent: res.itemcontent,
+            //     remark: res.remark
+            //   }
+            // })
+        })
         this.visible = true;
       },
       submitForm () {
@@ -186,10 +294,23 @@
             if(!this.model.id){
               httpurl+=this.url.add;
               method = 'post';
+              // 默认状态是禁用
+              this.model.status = 1
+              this.model.cmmsUpkeepItemDtoList = this.model.cmmsUpkeepItemDtoList.map((res) => {
+                return {
+                  id: res.id
+                }
+              })
             }else{
               httpurl+=this.url.edit;
                method = 'put';
+               this.model.cmmsUpkeepItemDtoList = this.model.cmmsUpkeepItemDtoList.map((res) => {
+                return {
+                  id: res.id
+                }
+              })
             }
+            console.log(999,this.model)
             httpAction(httpurl,this.model,method).then((res)=>{
               if(res.success){
                 that.$message.success(res.message);
@@ -204,6 +325,26 @@
          
         })
       },
+      // 通过已选设备获取保养项列表
+      handleAddUpkeepItem(){
+        console.log(this.model.equipmentid)
+        if (this.model.equipmentid == undefined) {
+          this.$message.error("请先选择设备!");
+        } else {
+          this.$refs.modalForm.add();
+          this.$refs.modalForm.title = "选择保养项";
+        }
+      },
+      // 处理子组件传过来的数据
+      handleCustomEvent(data) {
+        // 处理从子组件传递过来的数据
+        console.log("子组件传过来的数据:", data);
+        this.model.cmmsUpkeepItemDtoList = data;
+      }
     }
   }
-</script>
+</script>
+
+<style scoped>
+@import "~@/assets/less/uStyle.less";
+</style>

+ 3 - 3
src/views/module_cmms/upkeepPlan/modules/UpkeepPlanModal.vue

@@ -1,15 +1,15 @@
 <template>
-  <j-modal
+  <u-modal
     :title="title"
     :width="width"
     :visible="visible"
-    switchFullscreen
+    contentFull
     @ok="handleOk"
     :okButtonProps="{ class:{'jee-hidden': disableSubmit} }"
     @cancel="handleCancel"
     cancelText="关闭">
     <upkeep-plan-form ref="realForm" @ok="submitCallback" :disabled="disableSubmit"></upkeep-plan-form>
-  </j-modal>
+  </u-modal>
 </template>
 
 <script>

+ 149 - 0
src/views/module_cmms/upkeepPlan/modules/UpkeepPlanModalAdd.vue

@@ -0,0 +1,149 @@
+<template>
+    <j-modal
+    :title="title"
+    :width="width"
+    :visible="visible"
+    @ok="handleOk"
+    @cancel="handleCancel"
+    cancelText="关闭">
+
+        <a-table
+            ref="table"
+            size="middle"
+            :scroll="{x:true}"
+            bordered
+            rowKey="id"
+            :columns="columns"
+            :dataSource="dataSource"
+            :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
+            :pagination="false"
+            class="j-table-force-nowrap">
+        </a-table>
+
+    </j-modal>
+</template>
+
+<script>
+
+import { httpAction, getAction } from '@/api/manage'
+  
+  export default {
+    name: 'UpkeepPlanModalAdd',
+    components: {
+        
+    },
+    props: {
+      modelForm: {
+        type: Object,
+        default: function(){
+            return {} // 使用工厂函数返回默认值
+        }
+      },
+      dataList: {
+        type: Array,
+        default: function(){
+            return [] // 使用工厂函数返回默认值
+        }
+      },
+    },
+    data () {
+      return {
+        title:'',
+        width:1000,
+        visible: false,
+        /* table选中keys*/
+        selectedRowKeys: [],
+        /* table选中records*/
+        selectionRows: [],
+        columns: [
+          {
+            title:'保养项ID',
+            align:"center",
+            dataIndex: 'id'
+          },
+          {
+            title:'保养项名称',
+            align:"center",
+            dataIndex: 'itemname'
+          },
+          // {
+          //   title:'设备类型',
+          //   align:"center",
+          //   dataIndex: 'equiptypeName'
+          // },
+          {
+            title:'保养项编号',
+            align:"center",
+            dataIndex: 'itemcode'
+          },
+          {
+            title:'保养项标准',
+            align:"center",
+            dataIndex: 'itemcontent'
+          },
+          {
+            title:'备注',
+            align:"center",
+            dataIndex: 'remark'
+          },
+        ],
+        dataSource: [],
+        url: {
+            getList: "/cmmsUpkeepItem/cmmsUpkeepItem/getCmmsUpkeepItemByEqid"
+        },
+      }
+    },
+    methods: {
+      add () {
+        this.visible = true;
+        const a = {
+            id: this.modelForm.equipmentid
+        }
+        console.log(111,a)
+        getAction(this.url.getList,a).then((res) => {
+            console.log(res)
+            this.dataSource = res.result
+        })
+        this.selectList()
+      },
+      // 将以选中的值重新在列表中选中
+      selectList() {
+        console.log(111,this.dataList)
+        this.selectionRows = this.dataList
+        this.selectedRowKeys = this.dataList.map((res) => {
+            return res.id
+        })
+      },  
+      close () {
+        this.$emit('close');
+        this.visible = false;
+        this.onClearSelected()
+        this.selectionRows = this.dataList
+        this.selectedRowKeys = this.dataList.map((res) => {
+            return res.id
+        })
+      },
+      handleOk () {
+        console.log(this.selectionRows)
+        this.$emit('customEvent', this.selectionRows);
+        this.visible = false;
+      },
+      submitCallback(){
+        this.$emit('ok');
+        this.visible = false;
+      },
+      handleCancel () {
+        this.close()
+      },
+      onSelectChange(selectedRowKeys, selectionRows) {
+        this.selectedRowKeys = selectedRowKeys;
+        this.selectionRows = selectionRows;
+        console.log(this.selectedRowKeys,this.selectionRows)
+      },
+      onClearSelected() {
+        this.selectedRowKeys = [];
+        this.selectionRows = [];
+      },
+    }
+  }
+</script>

+ 289 - 125
src/views/module_ems/photovoltaic/pvDashboard/index.vue

@@ -1,173 +1,230 @@
 <template>
   <div class="page-header-index-wide">
     <a-row :gutter="24">
-      <a-col :sm="24" :md="12" :xl="18" :style="{ marginBottom: '24px' }">
+      <a-col :sm="24" :md="12" :xl="18" :style="{ marginBottom: '12px' }">
         <a-row :gutter="24">
-          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '24px' }">
-            <chart-card :loading="loading" title="总销售额" total="¥126,560">
-              <a-tooltip title="指标说明" slot="action">
-                <a-icon type="info-circle-o" />
-              </a-tooltip>
-              <div>
-                <trend flag="up" style="margin-right: 16px">
-                  <span slot="term">周同比</span>
-                  12%
-                </trend>
-                <trend flag="down">
-                  <span slot="term">日同比</span>
-                  11%
-                </trend>
+          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '12px', padding: '0px 0px 0px 12px' }">
+            <a-card
+              :body-style="{ padding: '10px 8px 8px' }"
+              :bordered="false"
+              style="background: linear-gradient(45deg, #8897f5, #9eaafd)"
+            >
+              <div class="chart-card-header">
+                <div class="meta">
+                  <span class="chart-card-title">电站数量</span>
+                </div>
+                <div class="total">
+                  <span>2 个</span>
+                </div>
               </div>
-              <template slot="footer">日均销售额<span>¥ 234.56</span></template>
-            </chart-card>
+            </a-card>
           </a-col>
-          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '24px' }">
-            <chart-card :loading="loading" title="订单量" :total="8846 | NumberFormat">
-              <a-tooltip title="指标说明" slot="action">
-                <a-icon type="info-circle-o" />
-              </a-tooltip>
-              <div>
-                <mini-area />
+          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '12px', padding: '0px 0px 0px 12px' }">
+            <a-card
+              :body-style="{ padding: '10px 8px 8px' }"
+              :bordered="false"
+              style="background: linear-gradient(45deg, #c67ffd, #d9a0fd)"
+            >
+              <div class="chart-card-header">
+                <div class="meta">
+                  <span class="chart-card-title">电站装机容量</span>
+                </div>
+                <div class="total">
+                  <span>{{elecdetail.fInstalledCapacity}} kW</span>
+                </div>
               </div>
-              <template slot="footer"
-                >日订单量<span> {{ '1234' | NumberFormat }}</span></template
-              >
-            </chart-card>
+            </a-card>
           </a-col>
-          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '24px' }">
-            <chart-card :loading="loading" title="支付笔数" :total="6560 | NumberFormat">
-              <a-tooltip title="指标说明" slot="action">
-                <a-icon type="info-circle-o" />
-              </a-tooltip>
-              <div>
-                <mini-bar :height="40" />
+          <a-col :sm="24" :md="12" :xl="8" :style="{ marginBottom: '12px' }">
+            <a-card
+              :body-style="{ padding: '10px 8px 8px' }"
+              :bordered="false"
+              style="background: linear-gradient(45deg, #07b59d, #09d5b8)"
+            >
+              <div class="chart-card-header">
+                <div class="meta">
+                  <span class="chart-card-title">当前发电功率</span>
+                </div>
+                <div class="total">
+                  <span>{{elecdetail.realGeneratingPower}} kwh</span>
+                </div>
               </div>
-              <template slot="footer">转化率 <span>60%</span></template>
-            </chart-card>
+            </a-card>
           </a-col>
         </a-row>
-        <a-row :gutter="24"> </a-row>
-      </a-col>
-
-      <a-col :sm="24" :md="12" :xl="6" :style="{ marginBottom: '24px' }">
-        <a-row>
-          <bar title="销售额趋势" :dataSource="barData" />
+        <a-row :gutter="24">
+          <a-col :sm="24" :md="12" :xl="24">
+            <div id="map" style="width: 100%; height: 775px"></div>
+          </a-col>
         </a-row>
+      </a-col>
 
+      <a-col :sm="24" :md="12" :xl="6" :style="{ padding: '0px 12px 0px 0px' }">
         <a-row>
           <a-col :span="24">
-            <a-card :loading="loading" :bordered="false" title="最近一周访问量统计" :style="{ marginTop: '24px' }">
+            <a-card :loading="loading" :body-style="{ padding: '10px 8px 8px' }" :bordered="false">
+              <span class="head-title">发电量信息</span>
               <a-row>
-                <a-col :span="6">
-                  <head-info title="今日IP" :content="loginfo.todayIp"></head-info>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>日发电量</span>
+                    <p>{{elecdetail.powerByDay}} kW·h</p>
+                  </div>
                 </a-col>
-                <a-col :span="2">
-                  <a-spin class="circle-cust">
-                    <a-icon slot="indicator" type="environment" style="font-size: 24px" />
-                  </a-spin>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>月发电量</span>
+                    <p>{{elecdetail.powerByMonth}} kW·h</p>
+                  </div>
                 </a-col>
-                <a-col :span="6">
-                  <head-info title="今日访问" :content="loginfo.todayVisitCount"></head-info>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>年发电量</span>
+                    <p>{{elecdetail.powerByYear}} kW·h</p>
+                  </div>
                 </a-col>
-                <a-col :span="2">
-                  <a-spin class="circle-cust">
-                    <a-icon slot="indicator" type="team" style="font-size: 24px" />
-                  </a-spin>
+              </a-row>
+              <a-divider style="margin: 8px 0" />
+              <span class="head-title">收益信息</span>
+              <a-row>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>日收益</span>
+                    <p>{{elecdetail.powerByDayProfit}} 元</p>
+                  </div>
                 </a-col>
-                <a-col :span="6">
-                  <head-info title="总访问量" :content="loginfo.totalVisitCount"></head-info>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>日收益</span>
+                    <p>{{elecdetail.powerByMonthProfit}} 元</p>
+                  </div>
                 </a-col>
-                <a-col :span="2">
-                  <a-spin class="circle-cust">
-                    <a-icon slot="indicator" type="rise" style="font-size: 24px" />
-                  </a-spin>
+                <a-col :span="8">
+                  <div class="head-info" :class="center && 'center'">
+                    <span>年收益</span>
+                    <p>{{elecdetail.powerByYearProfit}} 元</p>
+                  </div>
                 </a-col>
               </a-row>
-              <line-chart-multid :fields="visitFields" :dataSource="visitInfo"></line-chart-multid>
             </a-card>
           </a-col>
         </a-row>
+        <a-row>
+          <a-card
+            :loading="loading"
+            :body-style="{ padding: '10px 8px 8px' }"
+            :bordered="false"
+            title="当年社会效益"
+            style="margin-top: 12px"
+          >
+            <div class="chart-card-header">
+              <div class="societyTree">
+                <div class="societyTreeFont Cleft">
+                  <span class="treeF">节约标煤</span><br />
+                  <span class="treeF2">{{elecdetail.coalAmount}} t</span>
+                </div>
+                <div class="societyTreeFont Cright">
+                  <span class="treeF">减少二氧化碳排放</span><br />
+                  <span class="treeF2">{{elecdetail.co2Amount}} t</span>
+                </div>
+              </div>
+            </div>
+          </a-card>
+        </a-row>
+        <a-row>
+          <a-card
+            :body-style="{ padding: '0px 8px 8px' }"
+            :bordered="false"
+            title="年发电量"
+            style="margin-top: 12px;height:300px;"
+          >
+            <div class="totalEle-trend" ref="yearElec"></div>
+          </a-card>
+        </a-row>
       </a-col>
     </a-row>
   </div>
 </template>
 
 <script>
-import ChartCard from '@/components/ChartCard'
-import ACol from 'ant-design-vue/es/grid/Col'
-import ATooltip from 'ant-design-vue/es/tooltip/Tooltip'
-import MiniArea from '@/components/chart/MiniArea'
-import MiniBar from '@/components/chart/MiniBar'
-import MiniProgress from '@/components/chart/MiniProgress'
-import RankList from '@/components/chart/RankList'
-import Bar from '@/components/chart/Bar'
-import LineChartMultid from '@/components/chart/LineChartMultid'
-import HeadInfo from '@/components/tools/HeadInfo.vue'
-
-import Trend from '@/components/Trend'
-import { getLoginfo, getVisitInfo } from '@/api/api'
-
-const rankList = []
-for (let i = 0; i < 7; i++) {
-  rankList.push({
-    name: '白鹭岛 ' + (i + 1) + ' 号店',
-    total: 1234.56 - i * 100,
-  })
-}
-const barData = []
-for (let i = 0; i < 12; i += 1) {
-  barData.push({
-    x: `${i + 1}月`,
-    y: Math.floor(Math.random() * 1000) + 200,
-  })
-}
+import * as echarts from 'echarts'
+import { httpAction, getAction } from '@/api/manage'
+import { pvdata } from '../pvdata';
+
 export default {
   name: 'IndexChart',
-  components: {
-    ATooltip,
-    ACol,
-    ChartCard,
-    MiniArea,
-    MiniBar,
-    MiniProgress,
-    RankList,
-    Bar,
-    Trend,
-    LineChartMultid,
-    HeadInfo,
-  },
+  components: {},
   data() {
     return {
       loading: true,
       center: null,
-      rankList,
-      barData,
-      loginfo: {},
-      visitFields: ['ip', 'visit'],
-      visitInfo: [],
-      indicator: <a-icon type="loading" style="font-size: 24px" spin />,
+      elecdetail: {},
+      yearElecList: {}
     }
   },
   created() {
     setTimeout(() => {
       this.loading = !this.loading
     }, 1000)
-    this.initLogInfo()
+  },
+  mounted() {
+    this.initMap()
+    this.$nextTick(() => {
+    setTimeout(() => {
+      this.getTest();
+    }, 1000)
+      // this.getEnergyoverview()
+    })
   },
   methods: {
-    initLogInfo() {
-      getLoginfo(null).then((res) => {
-        if (res.success) {
-          Object.keys(res.result).forEach((key) => {
-            res.result[key] = res.result[key] + ''
-          })
-          this.loginfo = res.result
-        }
-      })
-      getVisitInfo().then((res) => {
-        if (res.success) {
-          this.visitInfo = res.result
-        }
+    getTest() {
+      var listData = pvdata.pvDashboardData;
+      console.log(listData)
+      this.elecdetail = listData.elecdetail;
+      this.yearElecList = listData.yearElecList;
+      
+      this.initChart();
+    },
+    initMap() {
+      // 百度地图API功能
+      var map = new BMap.Map('map') // 创建Map实例
+      map.centerAndZoom(new BMap.Point(121.455333, 37.471718), 15) // 初始化地图,设置中心点坐标和地图级别
+      //添加地图类型控件
+      map.addControl(
+        new BMap.MapTypeControl({
+          mapTypes: [BMAP_NORMAL_MAP],
+        })
+      )
+      map.setCurrentCity('烟台') // 设置地图显示的城市 此项是必须设置的
+      map.enableScrollWheelZoom(true) //开启鼠标滚轮缩放
+    },
+    initChart() {
+      var _this = this;
+      var chartDom = _this.$refs.yearElec;
+      var myChart = echarts.init(chartDom);
+      var option
+
+      option = {
+        xAxis: {
+          type: 'category',
+          data: ['1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月', '11月', '12月'],
+        },
+        yAxis: {
+          type: 'value',
+          name: '电量(kW·h)',
+        },
+        series: [
+          {
+            data: _this.yearElecList,
+            type: 'bar',
+          },
+        ],
+      }
+
+      option && myChart.setOption(option);
+      
+      window.addEventListener('resize', function () {
+        myChart.resize()
       })
     },
   },
@@ -175,6 +232,74 @@ export default {
 </script>
 
 <style lang="less" scoped>
+.chart-card-header {
+  position: relative;
+  overflow: hidden;
+  width: 100%;
+  height: 50px;
+
+  .meta {
+    position: relative;
+    overflow: hidden;
+    //   width: 100%;
+    color: #ffffff;
+    font-size: 20px;
+    line-height: 38px;
+    float: left;
+  }
+}
+
+.chart-card-action {
+  cursor: pointer;
+  position: absolute;
+  top: 0;
+  right: 0;
+}
+
+.chart-card-footer {
+  border-top: 1px solid #e8e8e8;
+  padding-top: 9px;
+  margin-top: 8px;
+
+  > * {
+    position: relative;
+  }
+
+  .field {
+    white-space: nowrap;
+    overflow: hidden;
+    text-overflow: ellipsis;
+    margin: 0;
+  }
+}
+
+.chart-card-content {
+  margin-bottom: 12px;
+  position: relative;
+  height: 46px;
+  width: 100%;
+
+  .content-fix {
+    position: absolute;
+    left: 0;
+    bottom: 0;
+    width: 100%;
+  }
+}
+
+.total {
+  overflow: hidden;
+  text-overflow: ellipsis;
+  word-break: break-all;
+  white-space: nowrap;
+  color: #ffffff;
+  // margin-top: 4px;
+  margin-bottom: 0;
+  font-size: 30px;
+  line-height: 38px;
+  height: 38px;
+  float: right;
+}
 .circle-cust {
   position: relative;
   top: 28px;
@@ -197,7 +322,7 @@ export default {
 /* 首页访问量统计 */
 .head-info {
   position: relative;
-  text-align: left;
+  text-align: center;
   padding: 0 32px 0 0;
   min-width: 125px;
 
@@ -221,5 +346,44 @@ export default {
       font-size: 1rem;
     }
   }
+  .bm-view {
+    width: 100%;
+    height: 300px;
+  }
+}
+.head-title {
+  font-size: 18px;
+}
+.societyTree {
+  background-image: url(../../../../assets/societyTree_light.png);
+  background-repeat: no-repeat;
+  background-size: 75%;
+  height: 190px;
+  background-position: 50% 0;
+
+  .societyTreeFont {
+    position: absolute;
+    font-size: small;
+    text-align: center;
+    .treeF {
+      color: #989c9f !important;
+    }
+    .treeF2 {
+      color: #333 !important;
+    }
+  }
+  .Cleft {
+    top: 74%;
+    left: 22%;
+  }
+  .Cright {
+    top: 62%;
+    left: 46%;
+    font-size: 14px;
+  }
+}
+
+.totalEle-trend {
+  height: 260px;
 }
 </style>

+ 25 - 0
src/views/module_ems/photovoltaic/pvdata.json

@@ -1,4 +1,29 @@
 {
+    "pvDashboardData": {
+        "elecdetail": {
+            "powerByDay": 37.47,
+            "powerByMonth": 5960.57,
+            "powerByYear": 5960.57,
+            "epiByDay": 0,
+            "epiByMonth": 0,
+            "epiByYear": 0,
+            "epiByLastDay": 0,
+            "epiByLastMonth": 0,
+            "epiByLastYear": 0,
+            "powerByDayProfit": 29.7212,
+            "powerByMonthProfit": 4801.287,
+            "powerByYearProfit": 4801.287,
+            "co2": 0.000581,
+            "latestUpdateTime": "2024-01-30",
+            "coalAmount": 1.8,
+            "co2Amount": 3.4,
+            "realGeneratingPower": 0.02,
+            "realGeneratingPowerTime": "2024-01-30 17:15:30",
+            "fInstalledCapacity": 121,
+            "effectiveHours": 49.27
+        },
+        "yearElecList": [7166.1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
+    },
     "CurveAnalysisData": [
         {
             "meterName": "PV0",

Разлика између датотеке није приказан због своје велике величине
+ 234 - 786
src/views/module_ems/photovoltaic/stationMonitor/index.vue