| | |
| | | <basic-container style="height: 350px;"> |
| | | |
| | | <!-- ç¼ç è§åä¿¡æ¯å±ç¤ºåºå --> |
| | | <basic-container> |
| | | <p style="margin-top: -12px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç¼ç è§å</p> |
| | | <avue-crud :option="optionRule" |
| | | <basic-container class="code-rule-container"> |
| | | <p style="margin-top: -5px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç¼ç è§å</p> |
| | | <avue-crud class="code-rule-crud" |
| | | :option="optionRule" |
| | | :table-loading="loading" |
| | | :data="data" |
| | | :page.sync="page" |
| | |
| | | <el-button size="small" |
| | | icon="icon-kelong" |
| | | plain |
| | | @click="cloneCodeSetting">å
é |
| | | @click="openCodeRuleDialog">å
é |
| | | </el-button> |
| | | <el-button size="small" |
| | | icon="icon-lianjiekelong" |
| | | style="font-size: 12px;" |
| | | plain |
| | | @click="handleDelete">ä»å
¶ä»è§åä¸å
éç æ®µ |
| | | @click="openOtherCodeRuleDialog">ä»å
¶ä»è§åä¸å
éç æ®µ |
| | | </el-button> |
| | | <el-button size="small" |
| | | icon="el-icon-s-help" |
| | |
| | | <el-button size="small" |
| | | icon="icon-qingkong" |
| | | plain |
| | | @click="handleDelete">æ¸
空ç å¼ |
| | | @click="clearAllCodeSec">æ¸
空ç å¼ |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | |
| | | <el-dialog title="ç¼ç è§å使ç¨èå´" |
| | | append-to-body |
| | | :visible.sync="codeRangeSettingBox" |
| | | width="800px"> |
| | | width="800px" |
| | | style="height: 116vh; margin-top: -10vh;"> |
| | | <avue-crud |
| | | :option="dialogeOption" |
| | | :table-loading="dialogLoading" |
| | |
| | | @refresh-change="refreshUseRangeChange"> |
| | | </avue-crud> |
| | | </el-dialog> |
| | | <!-- ç¼ç è§åç¸å
³å
éå¯¹è¯æ¡ --> |
| | | <!-- ç¼ç è§å,å
éå¯¹è¯æ¡ --> |
| | | <el-dialog title="å
éç¼ç è§å" |
| | | append-to-body |
| | | :visible.sync="cloneSettingBox" |
| | | width="800px"> |
| | | <clone-code></clone-code> |
| | | width="800px" |
| | | style="height: 120vh; margin-top: -14vh; overflow: hidden;"> |
| | | <div style="overflow-y: auto; height: 78vh"> |
| | | <el-row> |
| | | <el-form ref="form" :model="form" label-width="80px" :inline="true"> |
| | | <el-form-item label="ç¼å·" required> |
| | | <el-input v-model="cloneCodeRuleForm.id"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="åç§°" required> |
| | | <el-input v-model="cloneCodeRuleForm.name"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æè¿°" class="clone-input-textarea"> |
| | | <el-input :autosize="{ minRows: 3, maxRows: 5}" type="textarea" v-model="cloneCodeRuleForm.description"></el-input> |
| | | </el-form-item> |
| | | </el-form> |
| | | </el-row> |
| | | <el-row> |
| | | <p style="margin: -3vh 0px 16px 50%; font-weight: 500; font-size: 16px; color: #000;">ç æ®µç®¡ç</p> |
| | | <avue-crud |
| | | class="clone-avue-crud" |
| | | :option="cloneOption" |
| | | :table-loading="cloneTableLoading" |
| | | :data="cloneData" |
| | | @on-load="cloneDataOnLoad"> |
| | | <template slot="menu" slot-scope="scope"> |
| | | <el-button |
| | | type="text" |
| | | size="small" |
| | | icon="el-icon-arrow-up" |
| | | v-show="scope.row.orderNum > 1" |
| | | plain |
| | | @click="upOrderNum(scope.row)">ä¸ç§» |
| | | </el-button> |
| | | <el-button |
| | | type="text" |
| | | size="small" |
| | | icon="el-icon-arrow-down" |
| | | plain |
| | | @click="downOrderNum(scope.row)">ä¸ç§» |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | | </el-row> |
| | | </div> |
| | | <div slot="footer" class="dialog-footer" style="height: 50px; margin-top: -4vh;"> |
| | | <el-button @click="cloneSettingBox = false">å æ¶</el-button> |
| | | <el-button type="primary" @click="saveCloneCodeRule">ä¿ å</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | <!-- ç¼ç è§å,ä»å
¶ä»è§åå
éå¯¹è¯æ¡ --> |
| | | <el-dialog title="å
éç¼ç è§åçåºç¡ä¿¡æ¯" |
| | | append-to-body |
| | | :visible.sync="cloneOtherCodeRuleSettingBox" |
| | | width="800px" |
| | | style="height: 150vh; margin-top: -14vh;" |
| | | destroy-on-close> |
| | | <div> |
| | | <el-row> |
| | | <p style="margin-top: -12px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç¼ç è§å</p> |
| | | <avue-crud |
| | | class="other-clone-coderule-crud" |
| | | :option="cloneCodeRuleOption" |
| | | @row-click="codeOtherCloneRuleRowClick" |
| | | :table-loading="loading" |
| | | :data="data" |
| | | :page.sync="page" |
| | | ref="crudCloneCodeRuleOther" |
| | | @size-change="sizeChange" |
| | | @selection-change="selectionOtherCloneCodeRuleChange" |
| | | @on-load="onLoad"> |
| | | </avue-crud> |
| | | </el-row> |
| | | <el-row> |
| | | <p style="margin-top: -12px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç æ®µä¿¡æ¯</p> |
| | | <avue-crud |
| | | class="other-clone-codebasic-crud" |
| | | :option="cloneBasicOption" |
| | | ref="crudCloneCodeBasicOther" |
| | | :table-loading="loadingBasic" |
| | | :data="basicData" |
| | | @selection-change="selectionOtherCloneCodeBasicChange"> |
| | | </avue-crud> |
| | | </el-row> |
| | | </div> |
| | | <div slot="footer" class="dialog-footer" style="height: 50px; margin-top: -4vh;"> |
| | | <el-button @click="cloneOtherCodeRuleSettingBox = false">å æ¶</el-button> |
| | | <el-button type="primary" @click="saveOtherCodeBasic">ä¿ å</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | |
| | | <!-- åºç¡ç 段å±ç¤ºåºå --> |
| | | <basic-container> |
| | | <p style="margin-top: -12px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç æ®µç®¡ç</p> |
| | | <avue-crud :option="optionBasic" |
| | | <basic-container class="code-basicsec-container"> |
| | | <p style="margin-top: -5px; margin-bottom: 4px; font-weight: 570; font-size: 19px; color: #0e2d5f;">ç æ®µç®¡ç</p> |
| | | <avue-crud class="code-basic-crud" |
| | | :option="optionBasic" |
| | | ref="crudBasic" |
| | | :table-loading="loadingBasic" |
| | | :data="basicData" |
| | |
| | | <el-row v-show="!isShowFixedForm"> |
| | | <el-col :span="11"> |
| | | <basic-container> |
| | | <div class="box" style="height:65vh; margin-bottom:-40px"> |
| | | <div class="box classify_value_box" style="height:65vh; margin-bottom:-40px"> |
| | | <el-scrollbar style="border-bottom-right-radius:8px "> |
| | | <basic-container> |
| | | <div class="abox" style="height:54vh"> |
| | | <avue-tree |
| | | :data="attrClassifyTreeData" |
| | | :option="treeOption" |
| | | @node-click="nodeClick" |
| | | :data="classifyValueTreeData" |
| | | :option="classisyValueTreeOption" |
| | | @node-click="classisyValueTreeOnodeClick" |
| | | style="overflow-y: auto; height: 54vh"/> |
| | | </div> |
| | | </basic-container> |
| | | </el-scrollbar> |
| | | </div> |
| | | <div style="margin-top:20px; display: flex; align-items:center; justify-content:center;"> |
| | | <el-button size="mini" type="primary" icon="el-icon-arrow-up" class="button">ä¸ç§»</el-button> |
| | | <el-button size="mini" type="primary" icon="el-icon-arrow-down" class="button">ä¸ç§»</el-button> |
| | | <el-button size="mini" type="primary" icon="el-icon-arrow-up" class="button" @click="codeClassifyValueOpetion('up')">ä¸ç§»</el-button> |
| | | <el-button size="mini" type="primary" icon="el-icon-arrow-down" class="button" @click="codeClassifyValueOpetion('down')">ä¸ç§»</el-button> |
| | | </div> |
| | | </basic-container> |
| | | </el-col> |
| | |
| | | </el-form> |
| | | </div> |
| | | <div style="margin-top:20px; display: flex; align-items:center; justify-content:center;"> |
| | | <el-button size="mini" type="primary" icon="el-icon-circle-plus" class="button">æ·»å </el-button> |
| | | <el-button size="mini" type="success" plain icon="el-icon-edit-outline" class="button">ä¿®æ¹</el-button> |
| | | <el-button size="mini" type="danger" icon="el-icon-close" class="button">å é¤</el-button> |
| | | <el-button size="mini" type="warning" plain icon="el-icon-close" class="button">åæ¶</el-button> |
| | | <el-button size="mini" type="primary" icon="el-icon-circle-plus" class="button" @click="addCodeSecValue('codeclassifyvaluesec')">æ·»å </el-button> |
| | | <el-button :disabled="selectedFixedOrCodeclassifyValue==''" size="mini" type="success" plain icon="el-icon-edit-outline" class="button" @click="editCodeSecValue('codeclassifyvaluesec')">ä¿®æ¹</el-button> |
| | | <el-button :disabled="selectedFixedOrCodeclassifyValue==''" size="mini" type="danger" icon="el-icon-close" class="button" @click="delCodeSecValue('codeclassifyvaluesec')">å é¤</el-button> |
| | | <el-button size="mini" type="warning" plain icon="el-icon-close" class="button" @click = "clearFixedOrClassifyForm('codeclassifyvaluesec')">åæ¶</el-button> |
| | | </div> |
| | | </basic-container> |
| | | </el-col> |
| | |
| | | <basic-container> |
| | | <div class="box fixedbox" style="height:65vh; margin-bottom:-40px"> |
| | | <avue-crud |
| | | class="fixed-avue-crud" |
| | | ref="crudFixedValue" |
| | | :data="fixedValueData" |
| | | :option="fixedValueOption" |
| | |
| | | </avue-crud> |
| | | </div> |
| | | <div style="margin-top:20px;"> |
| | | <el-button size="mini" type="primary" icon="el-icon-success" class="button" @click="saveCodeFixedValueOption">ä¿å</el-button> |
| | | <el-button size="mini" type="primary" icon="el-icon-success" class="button" @click="saveCodeFixedOrClassifyValueOption('fixedValue')">ä¿å</el-button> |
| | | </div> |
| | | </basic-container> |
| | | </el-col> |
| | |
| | | destroy-on-close |
| | | @close="clearBasicAddForm"> |
| | | |
| | | |
| | | <!-- 第ä¸å±å¯¹è¯æ¡,æ·»å ç æ®µä¿¡æ¯å¯¹è¯æ¡ä¸çå
容 --> |
| | | <div class="total" style="overflow-y: auto; height: 70vh"> |
| | | <el-form :model="form" :rules="formRules" ref="form" > |
| | | <el-form :model="form"> |
| | | <span class="left"> |
| | | <el-form-item label="ç æ®µç¼å·:" :label-width="leftFormLabelWidth" required prop="id"> |
| | | <el-input v-model="form.id" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µç¼å·:" :label-width="leftFormLabelWidth" required> |
| | | <el-input v-model="form.id" :readonly="basicSecOnlyRead" ref="id"></el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="ç æ®µåç§°:" :label-width="leftFormLabelWidth" required prop="name"> |
| | | <el-input v-model="form.name" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µåç§°:" :label-width="leftFormLabelWidth" required> |
| | | <el-input ref="name" v-model="form.name" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ç æ®µç±»å" :label-width="leftFormLabelWidth" required prop="secType"> |
| | | |
| | | <el-form-item label="ç æ®µç±»å" :label-width="leftFormLabelWidth" required> |
| | | <el-select v-model="form.secType" placeholder="è¯·éæ©" @change="changeSectypeFormItems(null)" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in sectypeList" |
| | |
| | | <span class="right"> |
| | | <!-- åºå®ç 段 --> |
| | | <div v-show="form.secType==='codefixedsec' ? true:false"> |
| | | <el-form-item label="ç æ®µé¿åº¦ç±»å:" :label-width="rightFormLabelWidth" required prop="codeSecLengthType"> |
| | | <el-form-item label="ç æ®µé¿åº¦ç±»å:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.codeSecLengthType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeSecLengthType" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required prop="codeSecLength"> |
| | | <el-input v-model="form.codeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeSecLength" ref="codeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | </div> |
| | | <!-- 屿§ç 段 --> |
| | | <div v-show="form.secType==='codeattrsec' ? true:false"> |
| | | <el-form-item label="屿§:" :label-width="rightFormLabelWidth" required prop="referAttributeName"> |
| | | <el-form-item label="屿§:" :label-width="rightFormLabelWidth" required> |
| | | <el-input |
| | | placeholder="è¯·éæ©" |
| | | prefix-icon="el-icon-search" |
| | | readonly="true" |
| | | ref="referAttributeId" |
| | | v-model="form.referAttributeName" |
| | | @focus="openAttrSelectOrGetValue('attr')" |
| | | :disabled="basicSecOnlyRead"> |
| | |
| | | </div> |
| | | <!-- æµæ°´ç 段 --> |
| | | <div v-show="form.secType==='codeserialsec' ? true:false"> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required prop="codeSecLength"> |
| | | <el-input v-model="form.codeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeSecLength" ref="seriaCodeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æµæ°´å·çèµ·å§å¼:" :label-width="rightFormLabelWidth" prop="serialStart"> |
| | | <el-input v-model="form.serialStart" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="æµæ°´å·çèµ·å§å¼:" :label-width="rightFormLabelWidth"> |
| | | <el-input v-model.number="form.serialStart" ref="serialStart" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æµæ°´çæ¥é¿:" :label-width="rightFormLabelWidth" prop="serialStep"> |
| | | <el-input v-model="form.serialStep" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="æµæ°´çæ¥é¿:" :label-width="rightFormLabelWidth"> |
| | | <el-input v-model.number="form.serialStep" ref="serialStep" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ç¼ç è¡¥ä½æ¹å¼:" :label-width="rightFormLabelWidth" required prop="codeFillType"> |
| | | <el-form-item label="ç¼ç è¡¥ä½æ¹å¼:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.codeFillType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option label="左补ä½" value="codeattrsec" |
| | | v-for="item in codeFillType" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="è¡¥ä½æ¶çå符:" :label-width="rightFormLabelWidth" prop="codeFillSeparatorSelect"> |
| | | <el-select v-model="form.codeFillSeparatorSelect" filterable placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-form-item label="è¡¥ä½æ¶çå符:" :label-width="rightFormLabelWidth"> |
| | | <el-select v-model="form.codeFillSeparatorSelect" @blur="inputSelectBlur" filterable placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeFillSeparator" |
| | | :key="item.dictValue" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="å¡«å
é¿åº¦:" :label-width="rightFormLabelWidth" required prop="codeFillLength"> |
| | | <el-input v-model="form.codeFillLength" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="å¡«å
é¿åº¦:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeFillLength" ref="codeFillLength" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æµæ°´ä¸é:" :label-width="rightFormLabelWidth" required prop="codeFillLimit"> |
| | | <el-input v-model="form.codeFillLimit" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="æµæ°´ä¸é:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeFillLimit" ref="codeFillLimit" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æµæ°´æ¯å¦è¡¥ç :" :label-width="rightFormLabelWidth" required> |
| | | <el-switch v-model="form.codeFillFlag" :disabled="basicSecOnlyRead"></el-switch> |
| | |
| | | </div> |
| | | <!-- å±çº§ç 段 --> |
| | | <div v-show="form.secType==='codelevelsec' ? true:false"> |
| | | <el-form-item label="å±çº§ç±»å:" :label-width="rightFormLabelWidth" required prop="codeLevelType"> |
| | | <el-form-item label="å±çº§ç±»å:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.codeLevelType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeLevelType" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="å±çº§çå¼:" :label-width="rightFormLabelWidth" prop="codeLevelValue"> |
| | | <el-input v-model="form.codeLevelValue" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="å±çº§çå¼:" :label-width="rightFormLabelWidth"> |
| | | <el-input v-model.number="form.codeLevelValue" ref="codeLevelValue" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="å符æªåç±»å:" :label-width="rightFormLabelWidth" required prop="valueCutType"> |
| | | <el-form-item label="å符æªåç±»å:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.valueCutType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeCutType" |
| | |
| | | </div> |
| | | <!-- å¼ç¨ç 段 --> |
| | | <div v-show="form.secType==='coderefersec' ? true:false"> |
| | | <el-form-item label="åç
§å¼ç¨çä¸å¡ç±»å:" label-width="152px" required prop="referBtmId"> |
| | | <el-form-item label="åç
§å¼ç¨çä¸å¡ç±»å:" label-width="152px" required> |
| | | <el-input |
| | | ref="referBtmId" |
| | | placeholder="è¯·éæ©" |
| | | prefix-icon="el-icon-search" |
| | | readonly="true" |
| | |
| | | <i slot="suffix" class="el-icon-circle-close" @click="clearAttrDataByIcon('referBtmId')" style="margin-right: 5px;cursor: pointer;"></i> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="åç
§é
ç½®:" label-width="152px" required prop="referConfig"> |
| | | <el-form-item label="åç
§é
ç½®:" label-width="152px" required> |
| | | <el-input |
| | | ref="referConfig" |
| | | placeholder="è¯·éæ©" |
| | | prefix-icon="el-icon-search" |
| | | readonly="true" |
| | |
| | | </div> |
| | | <!-- æ¥æç æ®µ --> |
| | | <div v-show="form.secType==='codedatesec' ? true:false"> |
| | | <el-form-item label="æ¥ææ ¼å¼:" :label-width="rightFormLabelWidth" required prop="codeDateFormatStr"> |
| | | <el-input v-model="form.codeDateFormatStr" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="æ¥ææ ¼å¼:" :label-width="rightFormLabelWidth" required> |
| | | <el-input ref="codeDateFormatStr" v-model="form.codeDateFormatStr" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | </div> |
| | | <!-- åç±»ç æ®µ --> |
| | | <div v-show="form.secType==='codeclassifysec' ? true:false"> |
| | | <el-form-item label="ç æ®µé¿åº¦ç±»å:" :label-width="rightFormLabelWidth" required prop="codeSecLengthType"> |
| | | <el-form-item label="ç æ®µé¿åº¦ç±»å:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.codeSecLengthType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeSecLengthType" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required prop="codeSecLength"> |
| | | <el-input v-model="form.codeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeSecLength" ref="classCodeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ¯å¦èªå¨åé
åç±»å¼:" :label-width="rightFormLabelWidth"> |
| | | <el-switch v-model="form.matchClassifyValueFlag" :disabled="basicSecOnlyRead"></el-switch> |
| | |
| | | </div> |
| | | <!-- å¯åç æ®µ --> |
| | | <div v-show="form.secType==='codevariablesec' ? true:false"> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required prop="codeSecLength"> |
| | | <el-input v-model="form.codeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | <el-form-item label="ç æ®µçé¿åº¦:" :label-width="rightFormLabelWidth" required> |
| | | <el-input v-model.number="form.codeSecLength" ref="varCodeSecLength" :readonly="basicSecOnlyRead"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ç¼ç è¡¥ä½æ¹å¼:" :label-width="rightFormLabelWidth" required prop="codeFillType"> |
| | | <el-form-item label="ç¼ç è¡¥ä½æ¹å¼:" :label-width="rightFormLabelWidth" required> |
| | | <el-select v-model="form.codeFillType" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeFillType" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="è¡¥ä½æ¶çå符:" :label-width="rightFormLabelWidth"> |
| | | <el-select v-model="form.codeFillSeparatorSelect" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-select v-model="form.codeFillSeparatorSelect" filterable @blur="inputSelectBlur" placeholder="è¯·éæ©" :disabled="basicSecOnlyRead"> |
| | | <el-option |
| | | v-for="item in codeFillSeparator" |
| | | :key="item.dictValue" |
| | |
| | | |
| | | </el-dialog> |
| | | |
| | | <!-- 第äºå±å¯¹è¯æ¡,屿§ç 段ï¼å
¬å¼ç¼è¾æ¡å¼¹çª --> |
| | | <el-dialog title="å
¬å¼ç¼è¾æ¡" |
| | | append-to-body |
| | | :visible.sync="isShowformulaEdit" |
| | | @close="closeFormulaEdit" |
| | | width="78%" |
| | | style="height: 150vh; margin-top: -13vh; overflow: hidden"> |
| | | |
| | | <div style="overflow-y: auto; height: 80vh"> |
| | | <el-row> |
| | | <!-- 左侧å
¬å¼å
容 --> |
| | | <el-col :span="14" style="overflow: hidden"> |
| | | <el-card class="box-card" style="height: 33vh; overflow-y: auto; overflow-x: auto;"> |
| | | <div slot="header" class="clearfix"> |
| | | <span style="font-size: medium;" >å
¬å¼å
容</span> |
| | | <el-button type="primary" size="mini" style="float: right;" @click="saveFormulaContent">ç¡®å®</el-button> |
| | | <el-button type="warning" size="mini" style="margin-right: 10px; float: right;" @click="resetFormulaContent">æ¸
空å
容</el-button> |
| | | </div> |
| | | <div class="text item"> |
| | | <el-input type="textarea" :rows="5" style="width: 560px;" v-model="formulaContent"></el-input> |
| | | </div> |
| | | |
| | | </el-card> |
| | | </el-col> |
| | | <!-- å³ä¾§è¿ç®ç¬¦ --> |
| | | <el-col :span="10"> |
| | | <el-card class="box-card" style="height: 33vh; overflow-y: auto; overflow-x: auto;"> |
| | | <div slot="header" class="clearfix"> |
| | | <span style="font-size: medium;">è¿ç®ç¬¦</span> |
| | | </div> |
| | | <div class="text item"> |
| | | <div class="formula-editor"> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'7'})">7</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'8'})">8</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'9'})">9</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'/'})">/</button><br/> |
| | | </div> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'4'})">4</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'5'})">5</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'6'})">6</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'*'})">*</button><br/> |
| | | </div> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'1'})">1</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'2'})">2</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'3'})">3</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'>'})">-</button><br/> |
| | | </div> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'0'})">0</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'00'})">00</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'.'})">.</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'+'})">+</button><br/> |
| | | </div> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'->'})">-></button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'=='})">==</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'('})">(</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':')'})">)</button><br/> |
| | | </div> |
| | | <div class="one"> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'<'})"><</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'>'})">></button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'<='})"><=</button> |
| | | <button class="formula-editor-btn-sm" @click="dbClickAddContent({'formula':'>='})">>=</button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </el-card> |
| | | </el-col> |
| | | </el-row> |
| | | |
| | | <el-row> |
| | | <!-- 左侧å
¬å¼éæ©åºå --> |
| | | <el-col :span="14" style="overflow: hidden"> |
| | | <el-card class="box-card" style="height: 40vh; overflow-y: auto; overflow-x: auto;"> |
| | | <div slot="header" class="clearfix"> |
| | | <span style="font-size: medium;">å
¬å¼éæ©</span> |
| | | </div> |
| | | <div class="text item"> |
| | | <el-tabs v-model="activeName"> |
| | | |
| | | <el-tab-pane label="常ç¨" name="first"> |
| | | <el-table |
| | | :data="commonFormulaTableData" |
| | | :show-header="false" |
| | | @row-dblclick="dbClickAddContent" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="300"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="300"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | |
| | | <el-tab-pane label="è´¢å¡" name="second"> |
| | | <el-table |
| | | :data="financialFormulaTableData" |
| | | @row-dblclick="dbClickAddContent" |
| | | :show-header="false" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="300"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="300"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | |
| | | <el-tab-pane label="æ¥æ" name="third"> |
| | | <el-table |
| | | :data="dateFormulaTableData" |
| | | :show-header="false" |
| | | @row-dblclick="dbClickAddContent" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="300"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="300"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | |
| | | <el-tab-pane label="æ°å¦" name="fourth"> |
| | | <el-table |
| | | :data="mathFormulaTableData" |
| | | :show-header="false" |
| | | @row-dblclick="dbClickAddContent" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="300"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="300"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | |
| | | <el-tab-pane label="å
¶ä»" name="five"> |
| | | <el-table |
| | | :data="otherFormulaTableData" |
| | | @row-dblclick="dbClickAddContent" |
| | | :show-header="false" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="300"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="300"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | |
| | | </el-tabs> |
| | | |
| | | </div> |
| | | </el-card> |
| | | </el-col> |
| | | <!-- å³ä¾§åééæ©åºå --> |
| | | <el-col :span="10" style="overflow: hidden"> |
| | | <el-card class="box-card" style="height: 40vh; overflow-y: auto; overflow-x: auto;"> |
| | | <div slot="header" class="clearfix"> |
| | | <span style="font-size: medium;">åé</span> |
| | | </div> |
| | | <div class="text item"> |
| | | <el-tabs v-model="activeNameAttr"> |
| | | <el-tab-pane label="æ¬åºæ¯åé" name="first"> |
| | | <el-table |
| | | :data="thisSceneTableData" |
| | | @row-dblclick="dbClickAddContent" |
| | | :show-header="false" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="40"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="100"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="ç³»ç»åé" name="second"> |
| | | <el-table |
| | | :data="systemVariableTableData" |
| | | @row-dblclick="dbClickAddContent" |
| | | :show-header="false" |
| | | style="width: 100%"> |
| | | <el-table-column |
| | | prop="formula" |
| | | width="150"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | prop="desc" |
| | | width="150"> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-tab-pane> |
| | | </el-tabs> |
| | | </div> |
| | | </el-card> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | |
| | | </el-dialog> |
| | | <!-- 第äºå±å¯¹è¯æ¡,屿§ç 段ï¼å
¬å¼ç¼è¾æ¡å¼¹çªç»ä»¶ --> |
| | | <formula-editor ref="formulaEditor" |
| | | @updateFormulaContent="updateFormulaContent" |
| | | :thisSceneTableData="thisSceneTableData" |
| | | :systemVariableTableData="systemVariableTableData"> |
| | | </formula-editor> |
| | | |
| | | <!-- 第äºå±å¯¹è¯æ¡,为ãç¶åç±»ç æ®µãéåå¼å¼¹çª --> |
| | | <el-dialog title="为ãç¶åç±»ç æ®µãéåå¼" |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { gridCodeRule, getDetail, add, update, remove, listUseRange, updateStatus } from "@/api/code/mdmrule"; |
| | | import { gridCodeRule, getDetail, add, update, remove, listUseRange, updateStatus,clone,clearAllCode } from "@/api/code/mdmrule"; |
| | | import { |
| | | gridCodeBasicSec, |
| | | downOrderNum, |
| | | upOrderNum, |
| | | deleteData, |
| | | editSave, |
| | | getObjectByOid, |
| | | listDataByOids, |
| | | refDataGrid, |
| | | cloneCodeBasic, |
| | | addSave, |
| | | refDataGridClassifySec, |
| | | } from "@/api/code/codebasic"; |
| | | import { treeTopCodeClassify, listClassifyLinkAttr } from "@/api/code/codeclassify"; |
| | | import { gridCodeFixedValue,addSaveCodeFixedValue,deleteCodeFixedValue,editCodeFixedValue,saveOrder } from "@/api/code/codeFixedValue"; |
| | | import { treeCodeClassifyValue } from "@/api/code/codeClassifyValue"; |
| | | import { treeCodeClassifyValue,addSaveCodeClassifyValue,editCodeClassifyValue,deleteCodeClassifyValue,saveCodeClassifyValueOrder } from "@/api/code/codeClassifyValue"; |
| | | import { getDictionary } from "@/api/omd/dict"; |
| | | import optionBasic from "@/const/code/codebasic"; |
| | | import cloneOption from "@/const/code/cloneOption"; |
| | | import cloneBasicOption from "@/const/code/cloneBasicDialogOption"; |
| | | import cloneCodeRuleOption from "@/const/code/cloneCodeRuleDialogOption.js"; |
| | | import optionRule from "@/const/code/mdmrule"; |
| | | import attrOption from "@/const/code/selectAttrOptionDialog"; |
| | | import treeOption from "@/const/code/classifyTreeOptionDialog"; |
| | | import classisyValueTreeOption from "@/const/code/classisyValueTreeDialog"; |
| | | import parentClassifyParentOption from "@/const/code/parentClassifyParentOptionDialog"; |
| | | import referBtmOption from "@/const/code/referBtmDialog"; |
| | | import fixedValueOption from "@/const/code/fixedValueMgrDialog"; |
| | | import { getDictionary } from "@/api/omd/dict"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | |
| | | optionRule: optionRule, |
| | | data: [], |
| | | currentRuleLcStatus: '', |
| | | /*å
éæé®å¯¹è¯æ¡æ§å¶*/ |
| | | /*å
éå¯¹è¯æ¡æ§å¶åé*/ |
| | | cloneSettingBox: false, |
| | | optionBasic: optionBasic, |
| | | cloneTableLoading: false, |
| | | cloneOption: cloneOption, |
| | | cloneData: [], |
| | | cloneCodeRuleForm: { |
| | | id: '', |
| | | name: '', |
| | | description: '', |
| | | }, |
| | | /*ä»å
¶ä»è§åå
éç æ®µ*/ |
| | | cloneOtherCodeRuleSettingBox: false, |
| | | cloneBasicOption: cloneBasicOption, |
| | | cloneCodeRuleOption: cloneCodeRuleOption, |
| | | selectionOtherCloneCodeBasicList: [], // å½åéä¸çåºç¡ç 段 |
| | | |
| | | /*使ç¨èå´å¯¹è¯æ¡æ¾ç¤ºæ§å¶*/ |
| | | codeRangeSettingBox: false, |
| | | useRangeData: [], |
| | |
| | | }, |
| | | |
| | | /*åºç¡ç 段ç¸å
³æ°æ®*/ |
| | | optionBasic: optionBasic, |
| | | basicData:[], |
| | | loadingBasic: true, |
| | | selectionBasicList: [], |
| | |
| | | |
| | | //åç±»ç æ®µç å¼è¡¨å |
| | | codeClassifyForm: { |
| | | codeclassifysecoid: "", |
| | | codeClassifySecOid: "", |
| | | id: "", |
| | | name: "", |
| | | oid: "", |
| | | parentclassifyvalueoid: "", |
| | | }, |
| | | |
| | | classisyValueTreeOption: classisyValueTreeOption, //åç±»ç æ®µæ ç¸å
³é
置项 |
| | | classifyValueTreeData: [], |
| | | currentSelectTreeData: '', //å½åéä¸çåç±»ç 弿 èç¹ |
| | | |
| | | /* ä¸ºå±æ§éåå¼çªå£æ¾ç¤ºæå¼æ§å¶åé */ |
| | | isShowSelectAttrOption: false, |
| | |
| | | selectattrData: [], |
| | | selectAttrOptionLoading: false, |
| | | selectionChangeAttrList: [], |
| | | |
| | | /*å
¬å¼ç¼è¾æ¡å¯¹è¯æ¡ç¸å
³æ°æ®*/ |
| | | isShowformulaEdit: false, //å
¬å¼ç¼è¾æ¡å¯¹è¯æ¡æ¾ç¤ºæ§å¶ |
| | | formulaContent: '', //å
¬å¼ç¼è¾æ¡å
容 |
| | | activeName: 'first', //å½åæ´»å¨çtab |
| | | activeNameAttr: 'first', //åéä¸çå½åæ´»å¨tab |
| | | //常ç¨å
¬å¼ |
| | | commonFormulaTableData: [{ |
| | | "formula": 'if(compare,trueResult,falseResult)', |
| | | "desc": '妿compareç表达å¼ä¸ºtrueï¼åæ§è¡trueResultç表达å¼ï¼å¦åæ§è¡flaseResult.ä¾å¦if(3>2,2*(3+2),3/(2-4)),å¼çäº10', |
| | | }, |
| | | // 屿§ç 段ï¼å
¬å¼ç¼è¾æ¡ç»ä»¶çæ¬åºæ¯æ¾ç¤ºåéãä¸ç³»ç»åé |
| | | thisSceneTableData: [ |
| | | { |
| | | "formula": 'sum(douber1,douber2)', |
| | | "desc": 'ä¸¤ä¸ªæ ¼å¼ä¸ºdouberçåæ°æ±å', |
| | | }, |
| | | { |
| | | "formula": 'sub(douber1,douber2)', |
| | | "desc": 'æ ¼å¼ä¸ºdouberçåæ°douber1å廿 ¼å¼ä¸ºdouberçåæ°douber2', |
| | | }, |
| | | { |
| | | "formula": 'mul(douber1,douber2)', |
| | | "desc": 'ä¸¤ä¸ªæ ¼å¼ä¸ºdouberçåæ°ç¸ä¹', |
| | | }, |
| | | { |
| | | "formula": 'div(douber1,douber2)', |
| | | "desc": 'æ ¼å¼ä¸ºdouberçåæ°douber1é¤ä»¥æ ¼å¼ä¸ºdouberçåæ°douber2.å½douber2çäº0çæ¶åï¼è¿å0;妿é¤ä¸å°½çæ¶åä¿ç10ä½å°æ°', |
| | | }, |
| | | { |
| | | "formula": 'mod(int,int)', |
| | | "desc": 'æ±ä½æ°', |
| | | }, |
| | | { |
| | | "formula": 'toInt(string)', |
| | | "desc": '转æ¢ä¸ºintæ ¼å¼', |
| | | }, |
| | | { |
| | | "formula": 'doubleRound(string,count)', |
| | | "desc": 'å¤çdouberçå°æ°ä½æ°ï¼countè¡¨ç¤ºå°æ°ä½æ°', |
| | | }, |
| | | { |
| | | "formula": 'zeroIfNull(value)', |
| | | "desc": '妿忰çå¼ä¸ºnullæè
"",å°è¿å0', |
| | | }, |
| | | { |
| | | "formula": 'endsWith(string,str1)', |
| | | "desc": 'å符串stringæ¯ä¸æ¯ä»¥str1ç»å°¾', |
| | | }, |
| | | { |
| | | "formula": 'startsWith(string,str1)', |
| | | "desc": 'å符串stringæ¯å¦ä»¥str1å¼å¤´', |
| | | }, |
| | | { |
| | | "formula": 'charAt(string,index)', |
| | | "desc": 'è·åå符串stringä¸ç¬¬indexä½ç½®çå符ï¼å¦æé¿åº¦å°äºindexï¼åè¿å', |
| | | }, |
| | | { |
| | | "formula": 'equalsIgnoreCase(str1,str2)', |
| | | "desc": 'å符串str1åå符串str2æ¯å¦ç¸ç', |
| | | }, |
| | | { |
| | | "formula": 'indexOf(str1,str2)', |
| | | "desc": 'å符串str2å¨å符串str1ä¸é¦æ¬¡åºç°çä½ç½®', |
| | | }, |
| | | { |
| | | "formula": 'isEmpty(str1)', |
| | | "desc": 'åæ°str1æ¯å¦ä¸ºç©ºï¼å
¶ä¸nullè¿ä¸ªå符串ä¹è¡¨ç¤ºä¸ºç©º', |
| | | }, |
| | | { |
| | | "formula": 'lastIndexOf(str1,str2)', |
| | | "desc": 'å符串str2å¨å符串str1䏿ååºç°çä½ç½®', |
| | | }, |
| | | { |
| | | "formula": 'leftStr(str1,index)', |
| | | "desc": 'è·åindexä½ç½®å·¦ä¾§çææå符', |
| | | }, |
| | | { |
| | | "formula": 'rightStr(str1,str2)', |
| | | "desc": 'è·åindexä½ç½®å³ä¾§çææå符', |
| | | }, |
| | | { |
| | | "formula": 'length(str1)', |
| | | "desc": 'åæ°str1çé¿åº¦', |
| | | }, |
| | | { |
| | | "formula": 'mid(str1,start,end)', |
| | | "desc": 'è·åstr1çä»startå°endç´æ¥çå符串ï¼åºç°å¼å¸¸æ¶è¿å', |
| | | }, |
| | | { |
| | | "formula": 'tolowercase(str1)', |
| | | "desc": 'å°å符串str1转为å°å', |
| | | }, |
| | | { |
| | | "formula": 'touppercase(str1)', |
| | | "desc": 'å°å符串str1转为大å', |
| | | }, |
| | | { |
| | | "formula": 'trimzero(str1)', |
| | | "desc": 'å»é¤å符串str1ä¸ç0', |
| | | }, |
| | | { |
| | | "formula": 'MD5(str1)', |
| | | "desc": 'å°å符串è¿è¡MD5å å¯', |
| | | }, |
| | | ], |
| | | //è´¢å¡å
¬å¼ |
| | | financialFormulaTableData: [{ |
| | | "formula": 'toChinese(value)', |
| | | "desc": 'å°é¿æä¼¯æ°å转为为æ±å大忹å¼' |
| | | }, |
| | | { |
| | | "formula": 'getChineseCurrency(value)', |
| | | "desc": 'å°é¿æä¼¯æ°å转为为æ±åéé¢å¤§åæ¹å¼ï¼ä¸tochinessçåºå«æ¯è¿ä¸ªä¼æ¾ç¤ºå
ãè§ãå' |
| | | }, |
| | | { |
| | | "formula": 'setThmark(value)', |
| | | "desc": 'ä¸ºåæ°value设置ååä½' |
| | | formula: "${}", |
| | | desc: "", |
| | | } |
| | | ], |
| | | //æ¥æå
¬å¼ |
| | | dateFormulaTableData: [{ |
| | | "formula": 'compareDate(d1,d2)', |
| | | "desc": '对æ¯åæ°d1,d2ç大å°ãd1,d2为yyyy-MM-ddæ ¼å¼çæ¥æå符串' |
| | | systemVariableTableData: [ |
| | | { |
| | | formula: "#CURRENTUSER.OID#", |
| | | desc: "å½åç¨æ·ç主é®", |
| | | }, |
| | | { |
| | | "formula": 'nowDate()', |
| | | "desc": 'è·åå½åæ¥æ' |
| | | formula: "#CURRENTUSER.ID#", |
| | | desc: "å½åç¨æ·çè´¦æ·", |
| | | }, |
| | | { |
| | | "formula": 'chinaDate(d1)', |
| | | "desc": 'å°æ¶é´è½¬æ¢ä¸ºååï¼d1æ¯yyyy-MM-ddæ ¼å¼çæ¥æå符串' |
| | | formula: "#CURRENTTIME#", |
| | | desc: "å½åæ¶é´", |
| | | }, |
| | | { |
| | | "formula": 'dateAdd(d1,count)', |
| | | "desc": 'å¨d1çåºç¡ä¸æ·»å count天,d1为yyyy-MM-dd HH:mm:ssæ ¼å¼çæ¶é´å符串' |
| | | formula: "#CURRENTDATE#", |
| | | desc: "å½åæ¥æ", |
| | | }, |
| | | { |
| | | "formula": 'dateBalanceYear(sourceDate,targetDate,false)', |
| | | "desc": '计ç®ç¸å·®çå¹´ä»½ï¼æ¯å¦è®¡ç®å¹´é¾ï¼targetDate为""表示å½åæ¶é´ï¼ç¬¬ä¸ä¸ªåæ°ä¸ºtrue表示æå¤ä½çæä»½æè
å¤©æ°æ¶ï¼å°±å 1;' |
| | | formula: "#CURRENTDATETIME#", |
| | | desc: "å½åæ¥ææ¶é´", |
| | | }, |
| | | { |
| | | "formula": 'dateBalanceDay(sourceDate,targetDate)', |
| | | "desc": '计ç®ç¸å·®ç天æ°ï¼targetDate为""表示å½åæ¶é´' |
| | | formula: "#CURRENTUSER_NAME#", |
| | | desc: "å½åç¨æ·çå§å", |
| | | }, |
| | | { |
| | | "formula": 'dateformat(d1,format)<', |
| | | "desc": 'å°å½åçæ¥æï¼æ¶é´ï¼å符串转为æå®çå符串ï¼å¦æformatçå
容æç©ºæ ¼ï¼è¯·ä½¿ç¨&代æ¿' |
| | | formula: "#CURRENTUSER.SECRETGRADE#", |
| | | desc: "å½åç¨æ·å¯çº§", |
| | | }, |
| | | { |
| | | "formula": 'nowDatetime()', |
| | | "desc": 'è·åå½åæ¥æåæ¶é´ãæ ¼å¼ä¸ºyyyy-MM-dd HH:mm:ss' |
| | | formula: "#CURRENTUSER.IPSECRET#", |
| | | desc: "å½åç¨æ·çIPå¯çº§", |
| | | }, |
| | | { |
| | | "formula": 'dayOf(d1)', |
| | | "desc": 'è·åæ ¼å¼ä¸ºyyyy-MM-ddçæ¥æç天æ°' |
| | | formula: "#CURRENTUSER.BUSINESSUNIT#", |
| | | desc: "å½åç¨æ·æå±ä¸å¡åå
", |
| | | }, |
| | | { |
| | | "formula": 'nowMon()', |
| | | "desc": 'è·åå½åçæä»½ï¼æ ¼å¼ä¸ºMM' |
| | | formula: "#CURRENTUSER.BUSINESSUNITNAME#", |
| | | desc: "å½åç¨æ·æå±ä¸å¡åå
åç§°", |
| | | }, |
| | | { |
| | | "formula": 'monOf(d1)', |
| | | "desc": 'è·åæ¥æd1çæä»½æ°' |
| | | formula: "#CURRENTUSER.GROUPOID#", |
| | | desc: "å½åç¨æ·çé¨é¨ä¸»é®", |
| | | }, |
| | | { |
| | | "formula": 'nowTime()', |
| | | "desc": 'è·åå½åæ¶é´ï¼æ ¼å¼ä¸ºHH:mm:ss' |
| | | formula: "#CURRENTUSER.GROUPNAME#", |
| | | desc: "å½åç¨æ·æå±é¨é¨åç§°", |
| | | }, |
| | | { |
| | | "formula": 'nowYear()', |
| | | "desc": 'è·åå¹´ä»½ï¼æ ¼å¼ä¸ºyyyy' |
| | | formula: "#CURRENTUSER.EMAIL#", |
| | | desc: "å½åç¨æ·é®ä»¶å°å", |
| | | }, |
| | | { |
| | | "formula": 'yearOf()', |
| | | "desc": 'è·åæ¶é´d1ç年份' |
| | | } |
| | | ], |
| | | //æ°å¦å
¬å¼ |
| | | mathFormulaTableData: [{ |
| | | "formula": 'abs(value)', |
| | | "desc": 'æ±åæ°valueçç»å¯¹å¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'acos(value)', |
| | | "desc": 'æ±åæ°valueçåä½å¼¦ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'asin(value)', |
| | | "desc": 'æ±åæ°valueç忣弦ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'atan(value)', |
| | | "desc": 'æ±åæ°valueç忣åï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'cbrt(value)', |
| | | "desc": 'æ±åæ°valueçç«æ¹æ ¹ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'ceil(value)', |
| | | "desc": 'è¿åä¸å¤§äºåæ°valueçæå°æ´æ°ï¼ä¾å¦ceil(1.7)å°±çäº2ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'cos(value)', |
| | | "desc": 'æ±åæ°valueçä½å¼¦å¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'cosh(value)', |
| | | "desc": 'æ±åæ°valueçåæ²ä½å¼¦å¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'exp(n)', |
| | | "desc": 'æ¬§ææ° e çn次å¹ï¼nå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'floor(n)', |
| | | "desc": 'æ¬§ææ° e çn次å¹å1ï¼nå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'log(value)', |
| | | "desc": 'è¿åä¸å°äºåæ°valueçæå¤§æ´æ°ï¼ä¾å¦floor(1.7)çäº1ï¼nå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'log10(value)', |
| | | "desc": 'èªç¶å¯¹æ°,valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'log1p(value)', |
| | | "desc": '计ç®åºæ°ä¸º 10 ç对æ°,valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'random()', |
| | | "desc": 'è¿ååæ°ä¸ 1 ä¹åçèªç¶å¯¹æ°ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'rint(value)', |
| | | "desc": 'è¿åä¸ä¸ªä¼ªéæºæ°ï¼è¯¥å¼å¤§äºçäº 0.0 ä¸å°äº 1.0' |
| | | }, |
| | | { |
| | | "formula": 'round(value)', |
| | | "desc": 'è¿åå
¶å¼ææ¥è¿åæ°å¹¶ä¸æ¯æ´æ°ç double å¼ãå¦æä¸¤ä¸ªæ´æ°ç double å¼é½åæ ·æ¥è¿ï¼é£ä¹ç»æåå¶æ°ãç¹æ®æ
嵿¯ï¼å¦æåæ°å¼æ¯æ´æ°ï¼é£ä¹ç»æå°±æ¯è¯¥åæ°ãå¦æåæ°æ¯ NaN ææ ç©·å¤§ææ£é¶æè´é¶ï¼é£ä¹ç»æä¸åæ°ç¸å' |
| | | }, |
| | | { |
| | | "formula": 'signum(value)', |
| | | "desc": '符å·å½æ°ï¼å¦æåæ°ä¸º 0ï¼åè¿å 0ï¼å¦æåæ°å¤§äº 0ï¼ åè¿å 1.0ï¼å¦æåæ°å°äº 0ï¼åè¿å -1.0' |
| | | }, |
| | | { |
| | | "formula": 'sin(value)', |
| | | "desc": 'æ±åæ°valueçæ£å¼¦å¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'sinh(value)', |
| | | "desc": 'æ±åæ°valueçåæ²æ£å¼¦å¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'tan(value)', |
| | | "desc": 'æ±åæ°valueçæ£åå¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'tanh(value)', |
| | | "desc": 'æ±åæ°valueçåæ²æ£åå¼ï¼valueå¿
须为æ°åæ ¼å¼' |
| | | }, |
| | | { |
| | | "formula": 'max(v1,v2)', |
| | | "desc": 'æ±ä¸¤ä¸ªæ°ä¸çè¾å¤§çå¼ï¼v1,v2é½å¿
须为æ°åæ ¼å¼ï¼ä¾å¦max(3.2,3)å°±çäº3.2' |
| | | }, |
| | | { |
| | | "formula": 'min(v1,v2)', |
| | | "desc": 'æ±ä¸¤ä¸ªæ°ä¸çè¾å°çå¼ï¼v1,v2é½å¿
须为æ°åæ ¼å¼ï¼ä¾å¦max(3.2,3)å°±çäº3' |
| | | }, |
| | | { |
| | | "formula": 'sqrt(value)', |
| | | "desc": 'æ±å¹³æ¹æ ¹' |
| | | formula: "#CURRENTUSER.ROLENAME#", |
| | | desc: "å½åç¨æ·æå±è§è²åç§°", |
| | | }, |
| | | ], |
| | | //å
¶ä»å
¬å¼ |
| | | otherFormulaTableData: [{ |
| | | "formula": 'getcolvalue(servername,tablename,fieldname,pkField,pkValue)', |
| | | "desc": 'æ¥è¯¢servernameä¸tablenameæ°æ®åºè¡¨ä¸fieldnameåæ®µçå¼ï¼pkfield表示主é®çåæ®µåç§°ï¼pkValue表示主é®çå¼ï¼serverNameç°å¨é»è®¤ä¸ºlocalServer' |
| | | }, |
| | | ], |
| | | //æ¬åºæ¯åé |
| | | thisSceneTableData: [{ |
| | | "formula": '${}', |
| | | "desc": ' ' |
| | | }, |
| | | ], |
| | | //ç³»ç»åé |
| | | systemVariableTableData: [{ |
| | | "formula": '#CURRENTUSER.OID#', |
| | | "desc": 'å½åç¨æ·ç主é®' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.ID#', |
| | | "desc": 'å½åç¨æ·çè´¦æ·' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTTIME#', |
| | | "desc": 'å½åæ¶é´' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTDATE#', |
| | | "desc": 'å½åæ¥æ' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTDATETIME#', |
| | | "desc": 'å½åæ¥ææ¶é´' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER_NAME#', |
| | | "desc": 'å½åç¨æ·çå§å' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.SECRETGRADE#', |
| | | "desc": 'å½åç¨æ·å¯çº§' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.IPSECRET#', |
| | | "desc": 'å½åç¨æ·çIPå¯çº§' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.BUSINESSUNIT#', |
| | | "desc": 'å½åç¨æ·æå±ä¸å¡åå
' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.BUSINESSUNITNAME#', |
| | | "desc": 'å½åç¨æ·æå±ä¸å¡åå
åç§°' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.GROUPOID#', |
| | | "desc": 'å½åç¨æ·çé¨é¨ä¸»é®' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.GROUPNAME#', |
| | | "desc": 'å½åç¨æ·æå±é¨é¨åç§°' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.EMAIL#', |
| | | "desc": 'å½åç¨æ·é®ä»¶å°å' |
| | | }, |
| | | { |
| | | "formula": '#CURRENTUSER.ROLENAME#', |
| | | "desc": 'å½åç¨æ·æå±è§è²åç§°' |
| | | } |
| | | ], |
| | | |
| | | |
| | | /* ç¶åç±»ç æ®µå¯¹è¯æ¡ */ |
| | | isShowParentClassifyOption: false, //ç¶åç±»ç æ®µå¯¹è¯æ¡æ¾ç¤ºæ§å¶ |
| | |
| | | componentCodeFlag: false, //æ¯å¦åä¸ç¼ç |
| | | pkCodeRule: '', //æå±ç¼ç è§å |
| | | }, |
| | | formRules: { |
| | | id: [ |
| | | { required: true, message: '请è¾å
¥ç 段ç¼å·', trigger: 'blur' }, |
| | | ], |
| | | name: [ |
| | | { required: true, message: '请è¾å
¥ç 段åç§°', trigger: 'blur' }, |
| | | ], |
| | | secType: [ |
| | | { required: true, message: '请è¾å
¥ç 段åç§°', trigger: 'blur' }, |
| | | ], |
| | | codeSecLengthType: [ |
| | | { required: true, message: 'è¯·éæ©ç æ®µé¿åº¦ç±»å', trigger: 'change' }, |
| | | ], |
| | | codeSecLength: [ |
| | | { required: true, message: '请è¾å
¥ç 段çé¿åº¦', trigger: 'blur' }, |
| | | { type: 'number', message: 'ç æ®µçé¿åº¦å¿
须为æ°åå¼'} |
| | | ], |
| | | referAttributeName: [ |
| | | { required: true, message: 'è¯·éæ©å±æ§', trigger: 'blur' }, |
| | | ], |
| | | serialStart: [ |
| | | { type: 'number', message: 'ç æ®µçé¿åº¦å¿
须为æ°åå¼'} |
| | | ], |
| | | serialStep: [ |
| | | { type: 'number', message: 'ç æ®µçé¿åº¦å¿
须为æ°åå¼'} |
| | | ], |
| | | codeFillType: [ |
| | | { required: true, message: 'è¯·éæ©ç¼ç è¡¥ä½æ¹å¼', trigger: 'blur' }, |
| | | ], |
| | | // è®¾ç½®è¡¥ä½æ¶çå符ï¼éè¦èªå®ä¹æ¹æ³æ¥å夿 |
| | | codeFillSeparatorSelect: [ |
| | | { required: true, message: '请è¾å
¥è¡¥ä½æ¶çå符', trigger: 'blur' }, |
| | | ], |
| | | codeFillLength: [ |
| | | { required: true, message: '请è¾å
¥å¡«å
é¿åº¦', trigger: 'blur' }, |
| | | { type: 'number', message: 'å¡«å
é¿åº¦å¿
须为æ°åå¼'} |
| | | ], |
| | | codeFillLimit: [ |
| | | { required: true, message: '请è¾å
¥æµæ°´ä¸é', trigger: 'blur' }, |
| | | { type: 'number', message: 'æµæ°´ä¸éå¿
须为æ°åå¼'} |
| | | ], |
| | | codeLevelType: [ |
| | | { required: true, message: 'è¯·éæ©å±çº§ç±»å', trigger: 'change' }, |
| | | ], |
| | | codeLevelValue: [ |
| | | { type: 'number', message: 'å±çº§çå¼å¿
须为æ°åå¼'} |
| | | ], |
| | | valueCutType: [ |
| | | { required: true, message: 'è¯·éæ©å符æªåç±»å', trigger: 'change' }, |
| | | ], |
| | | referBtmId: [ |
| | | { required: true, message: '请éåç
§åºç¨çä¸å¡ç±»å', trigger: 'change' }, |
| | | ], |
| | | referConfig: [ |
| | | { required: true, message: 'è¯·éæ©åç
§é
ç½®', trigger: 'change' }, |
| | | ], |
| | | codeDateFormatStr: [ |
| | | { required: true, message: '请è¾å
¥æ¥ææ ¼å¼', trigger: 'blur' }, |
| | | ], |
| | | // formRules: { |
| | | // id: [ |
| | | // { required: true, message: '请è¾å
¥ç 段ç¼å·', trigger: 'blur' }, |
| | | // ], |
| | | // name: [ |
| | | // { required: true, message: '请è¾å
¥ç 段åç§°', trigger: 'blur' }, |
| | | // ], |
| | | // secType: [ |
| | | // { required: true, message: '请éä¸ç 段类å', trigger: 'change' }, |
| | | // ], |
| | | // codeSecLengthType: [ |
| | | // { required: true, message: 'è¯·éæ©ç æ®µé¿åº¦ç±»å', trigger: 'change' }, |
| | | // ], |
| | | // codeSecLength: [ |
| | | // { required: true, message: '请è¾å
¥ç 段çé¿åº¦', trigger: ['blur', 'change']}, |
| | | // { type: 'number', message: 'ç æ®µçé¿åº¦å¿
须为æ°åå¼',trigger: ['blur', 'change']} |
| | | // ], |
| | | // referAttributeName: [ |
| | | // { required: true, message: 'è¯·éæ©å±æ§', trigger: 'change' }, |
| | | // ], |
| | | // serialStart: [ |
| | | // { type: 'number', message: 'æµæ°´å·çèµ·å§å¼å¿
须为æ°åå¼',trigger: ['blur', 'change']} |
| | | // ], |
| | | // serialStep: [ |
| | | // { type: 'number', message: 'æµæ°´çæ¥é¿å¿
须为æ°åå¼',trigger: ['blur', 'change']} |
| | | // ], |
| | | // codeFillType: [ |
| | | // { required: true, message: 'è¯·éæ©ç¼ç è¡¥ä½æ¹å¼', trigger: ['blur', 'change']}, |
| | | // ], |
| | | // // è®¾ç½®è¡¥ä½æ¶çå符ï¼éè¦èªå®ä¹æ¥å夿 |
| | | // codeFillSeparatorSelect: [ |
| | | // { validator: validateCodeFill, trigger: ['blur', 'change'] }, |
| | | // ], |
| | | // codeFillLength: [ |
| | | // { required: true, message: '请è¾å
¥å¡«å
é¿åº¦', trigger: ['blur', 'change'] }, |
| | | // { type: 'number', message: 'å¡«å
é¿åº¦å¿
须为æ°åå¼',trigger: ['blur', 'change']} |
| | | // ], |
| | | // codeFillLimit: [ |
| | | // { required: true, message: '请è¾å
¥æµæ°´ä¸é', trigger: ['blur', 'change'] }, |
| | | // { type: 'number', message: 'æµæ°´ä¸éå¿
须为æ°åå¼',trigger: ['blur', 'change']} |
| | | // ], |
| | | // codeLevelType: [ |
| | | // { required: true, message: 'è¯·éæ©å±çº§ç±»å', trigger: 'change' }, |
| | | // ], |
| | | // codeLevelValue: [ |
| | | // { required: false, type: 'number', message: 'å±çº§çå¼å¿
须为æ°åå¼', trigger: 'change'} |
| | | // ], |
| | | // valueCutType: [ |
| | | // { required: true, message: 'è¯·éæ©å符æªåç±»å', trigger: 'change' }, |
| | | // ], |
| | | // referBtmId: [ |
| | | // { required: true, message: 'è¯·éæ©åç
§åºç¨çä¸å¡ç±»å', trigger: 'change' }, |
| | | // ], |
| | | // referConfig: [ |
| | | // { required: true, message: 'è¯·éæ©åç
§é
ç½®', trigger: 'change' }, |
| | | // ], |
| | | // codeDateFormatStr: [ |
| | | // { required: true, message: '请è¾å
¥æ¥ææ ¼å¼', trigger: ['blur', 'change'] }, |
| | | // ], |
| | | |
| | | }, |
| | | // }, |
| | | //æä¸¾åå¯è¾å¯éæ¥è¯¢ |
| | | sectypeList:[], //ç æ®µç±»å |
| | | codeSecLengthType:[], //ç æ®µé¿åº¦ç±»å |
| | |
| | | }, |
| | | }, |
| | | methods: { |
| | | |
| | | /* å
¬å¼ç¼è¾æ¡å
容æ¹å,åç»ä»¶ç¼è¾å®å
¬å¼ä¹åå
容忾æ¶è°ç¨ */ |
| | | updateFormulaContent(content){ |
| | | this.form.getValueClass = content; |
| | | }, |
| | | |
| | | /** éä¸åç
§å¼ç¨çä¸å¡ç±»åï¼ç¬¬äºå±åµå¥å¯¹è¯æ¡ï¼åå
¶ç¸å
³æ¹æ³ */ |
| | | saveSelectedreferBtm(){ |
| | |
| | | |
| | | |
| | | /** ç¶åç±»éæ©å¯¹è¯æ¡ï¼ç¬¬äºå±åµå¥å¯¹è¯æ¡ï¼åå
¶ç¸å
³æ¹æ³ */ |
| | | // ä¿åå½åç¶åç±»ç æ®µçéä¸è¡ï¼å¹¶è¿è¡åç»ä»¶åæ¾ |
| | | // ä¿åå½åç¶åç±»ç æ®µçéä¸è¡ï¼å¹¶è¿è¡åæ¾ |
| | | saveSelectedParentClassify(){ |
| | | //console.log(this.parentClassifySelectionList.length); |
| | | if(this.parentClassifySelectionList.length != 1){ |
| | |
| | | return false; |
| | | } |
| | | //è°ç¨åç»ä»¶å¹¶ä¼ éå½åéä¸çåæ°å¼ï¼å®ç°åæ¾ |
| | | this.form.parentClassifySecOid = this.parentClassifySelectionList[0].id; |
| | | this.form.parentClassifySecOid = this.parentClassifySelectionList[0].oid; |
| | | this.form.parentClassifySecText = this.parentClassifySelectionList[0].name; |
| | | //æ¸
空å½åéä¸çè¡ |
| | | this.parentClassifySelectionClear(); |
| | |
| | | }); |
| | | }, |
| | | |
| | | |
| | | /** æå¼å
¬å¼ç¼è¾æ¡ï¼ç¬¬äºå±åµå¥å¯¹è¯æ¡ï¼åå
¶ç¸å
³æ¹æ³ */ |
| | | openformulaEdit(){ |
| | | this.isShowformulaEdit = true; |
| | | }, |
| | | //å廿·»å å
¬å¼å
容 |
| | | dbClickAddContent(row){ |
| | | //console.log(row.formula); |
| | | this.formulaContent = this.formulaContent + row.formula; |
| | | }, |
| | | //æ¸
空å
¬å¼å
容 |
| | | resetFormulaContent(){ |
| | | this.formulaContent = ''; |
| | | }, |
| | | //å
³éæ¶æ¸
ç©ºä¸æ¬¡å
¬å¼å
容 |
| | | closeFormulaEdit(){ |
| | | this.resetFormulaContent(); |
| | | }, |
| | | //ç¼è¾å®æå
¬å¼å
容并忾 |
| | | saveFormulaContent(){ |
| | | //console.log(this.formulaContent); |
| | | if(this.formulaContent.trim == null || this.formulaContent.trim == ''){ |
| | | this.$message.warning("å
¬å¼å
容ä¸è½ä¸ºç©ºï¼"); |
| | | return; |
| | | } |
| | | //å
¬å¼å
容忾 |
| | | this.form.getValueClass = this.formulaContent; |
| | | this.isShowformulaEdit = false; |
| | | }, |
| | | |
| | | /** æå¼å±æ§éåå¼ï¼ç¬¬äºå±åµå¥å¯¹è¯æ¡ï¼åå
¶ç¸å
³æ¹æ³ */ |
| | | // è·åå½å被é䏿 èç¹çoid |
| | |
| | | }else{ |
| | | //åç±»ç æ®µ |
| | | this.isShowFixedForm = false; |
| | | this.loadClassifyValueData(row); |
| | | } |
| | | this.codefixedsecOrCodeclassifysecOid = row.oid; |
| | | this.isShowBasicSecCodeValueMgr = true; |
| | |
| | | this.fixedValueOptionLoading = false; |
| | | }) |
| | | }, |
| | | //å è½½åç±»ç æ®µç å¼ç®¡ç页é¢treeæ°æ® |
| | | |
| | | //åå»åºå®ç 段çç å¼è¡¨ä¸è¡æ¶è§¦åçäºä»¶ |
| | | selectedCodeValueRow(row){ |
| | | //console.log(row); |
| | |
| | | this.$message.warning("ç å¼ä¸è½ä¸ºç©ºï¼"); |
| | | return; |
| | | } |
| | | if(this.codeFixdForm.id.trim().length >= 12 ){ |
| | | this.$message.warning("ç å¼é¿åº¦ä¸è½å¤§äº12ï¼"); |
| | | return; |
| | | } |
| | | this.codeFixdForm.codeFixedSecOid = this.codefixedsecOrCodeclassifysecOid; |
| | | addSaveCodeFixedValue(this.codeFixdForm).then(() => { |
| | | this.loadFixedValueTableData({"oid":this.codefixedsecOrCodeclassifysecOid}); |
| | |
| | | window.console.log(error); |
| | | }); |
| | | }else { |
| | | |
| | | this.codeClassifyForm.codeClassifySecOid = this.codefixedsecOrCodeclassifysecOid; |
| | | console.log(this.codeClassifyForm); |
| | | addSaveCodeClassifyValue(this.codeClassifyForm).then(() => { |
| | | this.loadClassifyValueData({"oid":this.codefixedsecOrCodeclassifysecOid}); |
| | | this.clearFixedOrClassifyForm('codeclassifyvaluesec'); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }, error => { |
| | | this.$confirm(error, { |
| | | confirmButtonText: "ç¡®å®", |
| | | type: "error", |
| | | }) |
| | | }); |
| | | } |
| | | }, |
| | | // æ¸
空ç å¼è¡¨å |
| | | clearFixedOrClassifyForm(condition){ |
| | | //ç¹å»åæ¶æ¶æ¸
空表åä¸å½åéä¸çç å¼ï¼å¹¶ç¦ç¨æé® |
| | | this.selectedFixedOrCodeclassifyValue = ''; |
| | | //console.log(condition); |
| | | if(condition === "close"){ |
| | | this.codeFixdForm.id = ''; |
| | | this.codeFixdForm = this.$options.data().codeFixdForm; |
| | | this.codeClassifyForm = this.$options.data().codeClassifyForm; |
| | | } |
| | | if(condition === "codefixedsec" || condition === "close"){ |
| | | if(condition === "codefixedsec"){ |
| | | this.codeFixdForm.description = ''; |
| | | this.codeFixdForm.codeFixedSecOid = ''; |
| | | }else { |
| | | this.codeClassifyForm = ''; |
| | | this.codeClassifyForm = this.$options.data().codeClassifyForm; |
| | | } |
| | | }, |
| | | //ä¿®æ¹ç å¼ |
| | |
| | | window.console.log(error); |
| | | }); |
| | | }else { |
| | | |
| | | this.codeClassifyForm.oid = this.selectedFixedOrCodeclassifyValue.attributes.oid; |
| | | editCodeClassifyValue(this.codeClassifyForm).then(() => { |
| | | this.loadClassifyValueData({"oid":this.codefixedsecOrCodeclassifysecOid}) |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | } |
| | | |
| | | }, |
| | |
| | | delCodeSecValue(condition){ |
| | | //åºå®ç 段ç å¼å é¤ |
| | | if(condition == 'codefixedsec'){ |
| | | console.log(this.selectedFixedOrCodeclassifyValue.oid); |
| | | //console.log(this.selectedFixedOrCodeclassifyValue.oid); |
| | | this.$confirm("æ¯å¦å é¤è¿æ¡æ°æ®ï¼å¦æè¢«å¼ç¨å°ä¸è½è¢«å é¤ï¼", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | |
| | | return deleteCodeFixedValue({"oid": this.selectedFixedOrCodeclassifyValue.oid,"ts": ts}); |
| | | }) |
| | | .then(() => { |
| | | this.selectedFixedOrCodeclassifyValue = ''; |
| | | this.loadFixedValueTableData({"oid":this.codefixedsecOrCodeclassifysecOid}) |
| | | this.clearFixedOrClassifyForm('codefixedsec'); |
| | | this.$message({ |
| | |
| | | }); |
| | | }else{ |
| | | //åç±»ç æ®µç å¼å é¤ |
| | | |
| | | this.$confirm("æ¯å¦å é¤è¿æ¡æ°æ®ï¼å¦æè¢«å¼ç¨å°ä¸è½è¢«å é¤ï¼", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | let ts = new Date(this.selectedFixedOrCodeclassifyValue.ts).getTime(); |
| | | return deleteCodeClassifyValue({"oid": this.selectedFixedOrCodeclassifyValue.oid,"ts": ts}); |
| | | }) |
| | | .then(() => { |
| | | this.selectedFixedOrCodeclassifyValue = ''; |
| | | this.loadClassifyValueData({"oid":this.codefixedsecOrCodeclassifysecOid}) |
| | | this.clearFixedOrClassifyForm('codeclassifyvalue'); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }); |
| | | } |
| | | |
| | | }, |
| | | //对ç å¼è¡¨è¿è¡ï¼ä¸ç§»ãä¸ç§»ãç§»é¤æä½ |
| | | //对åºå®ç å¼è¡¨è¿è¡ï¼ä¸ç§»ãä¸ç§»ãç§»é¤æä½ |
| | | codeFixedValueOpetion(condition,row){ |
| | | //console.log(this.fixedValueData[row.$index].orderNum); |
| | | const index = row.$index; |
| | |
| | | } |
| | | //console.log(this.fixedValueData); |
| | | }, |
| | | //ä¿å对åºå®ç 段ç å¼çæä½ |
| | | saveCodeFixedValueOption(){ |
| | | //对åç±»ç å¼è¡¨è¿è¡ï¼ä¸ç§»ãä¸ç§»ãç§»é¤æä½ |
| | | codeClassifyValueOpetion(condition){ |
| | | //æ¤å¤æ¶åå°æ·±æµ
æ·è´é®é¢ï¼ä½æ¯æ§è¡ä¸ä¸ç§»ä¿åæä½ä¹åä¼éæ°å è½½treedataï¼æä»¥å½±åä¸å¤§ |
| | | let currentTreeList = this.getCodeClassifyValueTreeData(); |
| | | let saveData = []; |
| | | console.log(currentTreeList.treeList); |
| | | if(condition == 'up'){ |
| | | if(currentTreeList.index-1>=0){ |
| | | // è°æ´é¡ºåº |
| | | saveData[0] = currentTreeList.treeList[currentTreeList.index].attributes; |
| | | saveData[1] = currentTreeList.treeList[currentTreeList.index-1].attributes; |
| | | saveData[0].orderNum = parseInt(saveData[0].orderNum)-1; |
| | | saveData[1].orderNum = parseInt(saveData[1].orderNum)+1; |
| | | this.saveCodeFixedOrClassifyValueOption('classifyValue',saveData); |
| | | } |
| | | }else{ |
| | | if(currentTreeList.index+1<currentTreeList.treeList.length){ |
| | | // è°æ´é¡ºåº |
| | | saveData[0] = currentTreeList.treeList[currentTreeList.index].attributes; |
| | | saveData[1] = currentTreeList.treeList[currentTreeList.index+1].attributes; |
| | | saveData[0].orderNum = parseInt(saveData[0].orderNum)+1; |
| | | saveData[1].orderNum = parseInt(saveData[1].orderNum)-1; |
| | | this.saveCodeFixedOrClassifyValueOption('classifyValue',saveData); |
| | | } |
| | | } |
| | | console.log(saveData); |
| | | console.log(this.classifyValueTreeData); |
| | | }, |
| | | //éä¸è¢«è°æ´é¡ºåºç两个æ çèç¹ |
| | | getCodeClassifyValueTreeData(){ |
| | | const currentNodeTreeData = this.selectedFixedOrCodeclassifyValue; |
| | | /**èèå ç§æ
åµï¼ç¬¬ä¸ç§å½åä¸ç§»|ä¸ç§»æä½å·²ç»æ¯è¾¹çï¼ |
| | | ä¸éè¦è¦åå¤çï¼ç¬¬äºç§å½åä¸ºæ æ ¹èç¹ï¼ç¬¬ä¸ç§å½å为å¶åèç¹ |
| | | */ |
| | | //è¯´ææ¯æ ¹èç¹ï¼ç´æ¥æ¾å夿æ¯å¦æ¯è¾¹çå¼ |
| | | if(currentNodeTreeData.parentId.trim() == ''){ |
| | | return this.findTreeIndex(this.classifyValueTreeData,currentNodeTreeData.oid,true); |
| | | }else{ |
| | | //说æä¸æ¯æ ¹èç¹,å
æ¾å°ç¶èç¹åæ¾å°åèç¹,夿æ¯å¦æ¯è¾¹çå¼ |
| | | return this.findTreeIndex(this.classifyValueTreeData,currentNodeTreeData.parentId,false); |
| | | } |
| | | }, |
| | | /** |
| | | * æ¾åä¸ä¸ªååä¸ä¸ªå
ç´ |
| | | * @treeList æ¥æ¾çæ°ç» |
| | | * @conditionOid ç¨æ¥æ¥æ¾å¤æçæ¡ä»¶ |
| | | * @isTreeRoot æ¯å¦ç¶èç¹ |
| | | * @rreturn è¿åç¸é»çèç¹ |
| | | */ |
| | | findTreeIndex(treeList,conditionOid,isTreeRoot){ |
| | | for(let index=0;index<treeList.length;index++){ |
| | | if(treeList[index].oid==conditionOid){ |
| | | if(isTreeRoot){ |
| | | let resData = { |
| | | "index":index, |
| | | "treeList":treeList, |
| | | } |
| | | return resData; |
| | | }else{ |
| | | return this.findTreeIndex(this.classifyValueTreeData[index].children,this.selectedFixedOrCodeclassifyValue.oid,true); |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | //ä¸ç§»ä¸ç§»çæä½çä¿å |
| | | saveCodeFixedOrClassifyValueOption(condition,editOrderNumdata){ |
| | | //ä¿å对åºå®ç 段ç å¼çä¸ç§»ä¸ç§»ç§»åºçæä½ |
| | | if(condition == "fixedValue"){ |
| | | let data = { |
| | | "codeFixedSecOid": this.codefixedsecOrCodeclassifysecOid, |
| | | "dtoList": JSON.stringify(this.fixedValueData), |
| | | } |
| | | saveOrder(data).then(() => { |
| | | //æ§è¡å®ä¿åä¹åå°å½åéä¸ç对象æ¸
空 |
| | | this.selectedFixedOrCodeclassifyValue = ''; |
| | | this.$message({ |
| | | type: "success", |
| | | message: "ä¿åæå!" |
| | |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | }else { |
| | | //ä¿å对åç±»ç å¼ç 段ç å¼çä¸ç§»ä¸ç§»ç§»åºçæä½ |
| | | saveCodeClassifyValueOrder({ |
| | | "codeClassifySecOid": this.codefixedsecOrCodeclassifysecOid, |
| | | "dtoList": JSON.stringify(editOrderNumdata), |
| | | }).then(() => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "ä¿åæå!" |
| | | }); |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | this.loadClassifyValueData({"oid":this.codefixedsecOrCodeclassifysecOid}); |
| | | } |
| | | |
| | | }, |
| | | //åç±»ç 弿 dataå è½½ |
| | | loadClassifyValueData(row){ |
| | | //console.log(row); |
| | | let condtionData = { |
| | | "queryAllLevel": true, |
| | | "loadType": "all", |
| | | "multipleSelect": false, |
| | | "isMuti": false, |
| | | "isQueryAllColumn": true, |
| | | 'conditionMap[codeclassifysecoid]':row.oid, |
| | | }; |
| | | treeCodeClassifyValue(condtionData).then( res=> { |
| | | this.classifyValueTreeData = res.data; |
| | | //console.log(res.data); |
| | | }); |
| | | }, |
| | | //åç±»ç 弿 å廿¶è§¦åçäºä»¶ |
| | | classisyValueTreeOnodeClick(node){ |
| | | //console.log(node); |
| | | this.selectedFixedOrCodeclassifyValue = node; |
| | | this.codeClassifyForm.codeClassifySecOid = node.attributes.codeClassifySecOid; |
| | | this.codeClassifyForm.id = node.attributes.id; |
| | | this.codeClassifyForm.name = node.attributes.name; |
| | | this.codeClassifyForm.parentClassifyValueOid = node.attributes.oid; |
| | | //console.log(this.codeClassifyForm); |
| | | }, |
| | | |
| | | |
| | | /** åºç¡ç 段ç¸å
³æ¹æ³ */ |
| | | //鲿¢æå¼è¿ç¼è¾çªå£ä¹å表åä¸åå¨å¼ï¼æä»¥éè¦æ¸
空ä¹ååå§åform表å |
| | | //鲿¢æå¼è¿ç¼è¾çªå£ä¹å表åä¸åå¨å¼ï¼æä»¥éè¦æ¸
空,å¹¶åå§åform表å屿§ |
| | | clearBasicAddForm(){ |
| | | this.form = ''; |
| | | this.form = { |
| | | secType:'codefixedsec' |
| | | }; |
| | | this.changeSectypeFormItems(null); |
| | | this.form = this.$options.data().form;; |
| | | // this.changeSectypeFormItems(null); |
| | | }, |
| | | // æå¼æ°å¢çªå£ |
| | | addBasicCodeSec(){ |
| | |
| | | this.showbtn = true; |
| | | this.basicSecOnlyRead = false; |
| | | //为formç»å®å¼ |
| | | this.changeSectypeFormItems(row); |
| | | }else{ |
| | | this.basicSecDialogTitle = 'æ¥çç æ®µä¿¡æ¯'; |
| | | this.showbtn = false; |
| | | this.basicSecOnlyRead = true; |
| | | this.changeSectypeFormItems(row); |
| | | } |
| | | //console.log(this.form); |
| | | this.changeSectypeFormItems(condition == 'add' ? null:row); |
| | | this.addBasicCodeSettingBox = true; |
| | | }, |
| | | // æ°å¢åºç¡ç 段 |
| | | saveOrEditBasicCode(){ |
| | | if(this.selectionList[0].oid == null || this.selectionList[0].oid == ''){ |
| | | this.$message.warning('缺失å¿
è¦åæ°ï¼è¯·éæ°éæ©ç¼ç è§ååéè¯!'); |
| | | this.$message.warning('缺失å¿
è¦åæ°ï¼è¯·éæ°éæ©ç¼ç è§åååè¯!'); |
| | | return; |
| | | } |
| | | this.form.pkCodeRule = this.selectionList[0].oid; |
| | | //console.log(this.form); |
| | | if(this.form.oid == '' || this.form.oid == null){ |
| | | if(this.checkForm()){ |
| | | addSave(this.form).then(() => { |
| | | this.$message({ |
| | | type: "success", |
| | |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | // å
³éå¯¹è¯æ¡ |
| | | this.addBasicCodeSettingBox = false |
| | | } |
| | | |
| | | }else{ |
| | | editSave(this.form).then(() => { |
| | | // å
³éå¯¹è¯æ¡ |
| | | this.addBasicCodeSettingBox = false |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | |
| | | window.console.log(error); |
| | | }); |
| | | } |
| | | |
| | | // å
³éçªå£ |
| | | this.addBasicCodeSettingBox = false |
| | | // ç¹å»æ°å¢åºç¡ç 段,å
³éçªå£ä¹å触åéæ°å è½½ |
| | | this.loadBasic(this.selectionList[0]); |
| | | }, |
| | | // å 为elementuiçè¡¨åæ ¡éªè®¾ç½®ä¸ä¸æä»¥éç¨å¤æçæ¹å¼æ¥åè¡¨åæ£éªæ¹å¼ |
| | | checkForm(){ |
| | | let form = this.form; |
| | | //console.log(form); |
| | | const regNumber = /^[0-9]+\.{0,1}[0-9]*$/; //æ°åæå°æ°æ£åæ ¡éª |
| | | const tipsMsg = "å¿
填项ä¸è½ä¸ºç©º"; |
| | | if(form.id == ''){ |
| | | this.$message.warning("(ç æ®µç¼å·)"+tipsMsg); |
| | | this.$refs.id.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.name == ''){ |
| | | this.$message.warning("(ç æ®µåç§°)"+tipsMsg); |
| | | this.$refs.name.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.secType == ''){ |
| | | this.$message.warning("(ç æ®µç±»å)"+tipsMsg); |
| | | this.$refs.secType.$el.querySelector('select').focus(); |
| | | return false; |
| | | } |
| | | if(form.secType==='codefixedsec'){ |
| | | //åºå®ç 段 |
| | | if(form.codeSecLengthType == ''){ |
| | | this.$message.warning("(ç æ®µé¿åº¦ç±»å)"+tipsMsg); |
| | | this.$refs.codeSecLengthType.$el.querySelector('select').focus(); |
| | | return false; |
| | | } |
| | | if(form.codeSecLength == ''){ |
| | | this.$message.warning("(ç æ®µé¿åº¦)"+tipsMsg); |
| | | this.$refs.codeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeSecLength)){ |
| | | this.$message.warning("ç æ®µçé¿åº¦å¿
须为æ°åå¼"); |
| | | this.$refs.codeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codeattrsec'){ |
| | | //屿§ç 段 |
| | | if(form.referAttributeId == ''){ |
| | | this.$message.warning('(屿§)'+tipsMsg); |
| | | this.$refs.referAttributeId.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codeserialsec'){ |
| | | console.log(form.codeFillType); |
| | | //æµæ°´ç 段 |
| | | if(form.codeSecLength == ''){ |
| | | this.$message.warning('(ç æ®µçé¿åº¦)'+tipsMsg); |
| | | this.$refs.seriaCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeSecLength)){ |
| | | this.$message.warning('ç æ®µçé¿åº¦å¿
须为æ°åå¼'); |
| | | this.$refs.seriaCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.serialStart)){ |
| | | this.$message.warning('æµæ°´å·çèµ·å§å¼å¿
须为æ°åå¼'); |
| | | this.$refs.serialStart.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.serialStep)){ |
| | | this.$message.warning('æµæ°´çæ¥é¿å¿
须为æ°åå¼'); |
| | | this.$refs.serialStep.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.codeFillType == ''){ |
| | | this.$message.warning('(ç¼ç è¡¥ä½æ¹å¼)'+tipsMsg); |
| | | return false; |
| | | } |
| | | if(form.codeFillType != 'ä¸è¡¥ä½' && form.codeFillSeparatorSelect == ''){ |
| | | this.$message.warning('å½è¡¥ä½æ¹å¼ä¸ºå·¦è¡¥ä½æè
å³è¡¥ä½çæ¶åï¼è¡¥ä½å符ä¸è½ä¸ºç©º'); |
| | | return false; |
| | | } |
| | | if(form.codeFillLength == ''){ |
| | | this.$message.warning('å¡«å
é¿åº¦ä¸è½ä¸ºç©º'); |
| | | this.$refs.codeFillLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeFillLength)){ |
| | | this.$message.warning('å¡«å
é¿åº¦å¿
须为æ°åå¼'); |
| | | this.$refs.codeFillLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.codeFillLimit == ''){ |
| | | this.$message.warning('(æµæ°´ä¸é)'+tipsMsg); |
| | | this.$refs.codeFillLimit.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeFillLimit)){ |
| | | this.$message.warning('æµæ°´ä¸éå¿
须为æ°åå¼'); |
| | | this.$refs.codeFillLimit.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.codeFillFlag == ''){ |
| | | this.$message.warning('(æµæ°´æ¯å¦è¡¥ç )'+tipsMsg); |
| | | this.$refs.switch.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codelevelsec'){ |
| | | //å±çº§ç 段 |
| | | if(form.codeLevelType == ''){ |
| | | this.$message.warning('(å±çº§ç±»å)'+tipsMsg); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeLevelValue)){ |
| | | this.$message.warning('å±çº§çå¼)åªè½å¡«åæ°å'); |
| | | this.$refs.codeLevelValue.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.valueCutType == ''){ |
| | | this.$message.warning('(å符æªåç±»å)'+tipsMsg); |
| | | this.$refs.valueCutType.$el.querySelector('select').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='coderefersec'){ |
| | | //å¼ç¨ç 段 |
| | | if(form.referBtmId == ''){ |
| | | this.$message.warning('(åç
§å¼ç¨çä¸å¡ç±»å)'+tipsMsg); |
| | | this.$refs.referBtmId.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.referConfig == ''){ |
| | | this.$message.warning('(åç
§é
ç½®)'+tipsMsg); |
| | | this.$refs.referConfig.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codedatesec'){ |
| | | //æ¥æç æ®µ |
| | | if(form.codeDateFormatStr == ''){ |
| | | this.$message.warning('(æ¥ææ ¼å¼)'+tipsMsg); |
| | | this.$refs.codeDateFormatStr.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codeclassifysec'){ |
| | | //åç±»ç æ®µ |
| | | if(form.codeSecLengthType == ''){ |
| | | this.$message.warning('(ç æ®µé¿åº¦ç±»å)'+tipsMsg); |
| | | return false; |
| | | } |
| | | if(form.codeSecLength == ''){ |
| | | this.$message.warning('(ç æ®µé¿åº¦)'+tipsMsg); |
| | | this.$refs.classCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeSecLength)){ |
| | | this.$message.warning('ç æ®µçé¿åº¦å¿
须为æ°åå¼'); |
| | | this.$refs.classCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | }else if(this.form.secType==='codevariablesec'){ |
| | | //å¯åç æ®µ |
| | | if(form.codeSecLength == ''){ |
| | | this.$message.warning('(ç æ®µé¿åº¦)'+tipsMsg); |
| | | this.$refs.varCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(!regNumber.test(form.codeSecLength)){ |
| | | this.$message.warning('ç æ®µçé¿åº¦å¿
须为æ°åå¼'); |
| | | this.$refs.classCodeSecLength.$el.querySelector('input').focus(); |
| | | return false; |
| | | } |
| | | if(form.codeFillType == ''){ |
| | | this.$message.warning('(ç¼ç è¡¥ä½æ¹å¼)'+tipsMsg); |
| | | return false; |
| | | } |
| | | if(form.codeFillType != 'ä¸è¡¥ä½' && form.codeFillSeparatorSelect == ''){ |
| | | this.$message.warning('å½è¡¥ä½æ¹å¼ä¸ºå·¦è¡¥ä½æè
å³è¡¥ä½çæ¶åï¼è¡¥ä½å符ä¸è½ä¸ºç©º'); |
| | | return false; |
| | | } |
| | | } |
| | | return true; |
| | | }, |
| | | // å¤ææ°æ®æ¯å¦éæ©ä»¥ååªè½éæ©åæ¡æ°æ® |
| | | tipsMessage(list){ |
| | |
| | | }, |
| | | // ç¹å»è§¦åå è½½åºç¡ç æ®µä¿¡æ¯ |
| | | loadBasic(row){ |
| | | if(this.cloneSettingBox){ |
| | | this.cloneTableLoading = true; |
| | | }else{ |
| | | this.loadingBasic = true; |
| | | } |
| | | //console.log(row.oid); |
| | | //åå¨å½åå
³èçç¼ç è§åç¸å
³ä¿¡æ¯ |
| | | this.currentCodeRuleOid = row.oid; |
| | | this.currentRuleLcStatus = row.lcStatus; |
| | | gridCodeBasicSec(1, -1, {"pkCodeRule":row.oid}).then(res => { |
| | | const data = res.data.data; |
| | | // console.log(data); |
| | | if(this.cloneSettingBox){ |
| | | this.cloneData = data.records; |
| | | // console.log(tihs.cloneData); |
| | | this.cloneTableLoading = false; |
| | | }else { |
| | | this.basicData = data.records; |
| | | //console.log(this.basicData); |
| | | this.loadingBasic = false; |
| | | } |
| | | }); |
| | | }, |
| | | // åºç¡ç 段é䏿¶è§¦å |
| | |
| | | }, |
| | | //åå»ç¼ç è§åå®ç°è¡éæ© |
| | | codeRuleRowClick (row) { |
| | | //console.log(row); |
| | | this.$refs.crud.toggleRowSelection(row); |
| | | this.$refs.crud.toggleSelection(); |
| | | this.selectionList = row; |
| | | this.$refs.crud.setCurrentRow(row); |
| | | //this.$refs.crud.toggleRowSelection(row); //éä¸å½åè¡ |
| | | this.loadBasic(row); |
| | | }, |
| | | // å¯ç¨ä¸åç¨ |
| | |
| | | window.console.log(error); |
| | | }); |
| | | }, |
| | | // å
é |
| | | cloneCodeSetting() { |
| | | if (this.selectionList.length === 0) { |
| | | this.$message.warning("è¯·éæ©è³å°ä¸æ¡æ°æ®!"); |
| | | // æå¼ç¼ç è§åå
éå¯¹è¯æ¡ |
| | | openCodeRuleDialog() { |
| | | if (!this.tipsMessage(this.selectionList)) { |
| | | return; |
| | | } |
| | | if (this.selectionList.length > 1) { |
| | | this.cloneSettingBox = true; |
| | | this.cloneCodeRuleForm.id = this.selectionList[0].id; |
| | | this.cloneCodeRuleForm.name = this.selectionList[0].name; |
| | | this.cloneCodeRuleForm.description = this.selectionList[0].description; |
| | | this.loadBasic({"oid": this.selectionList[0].oid}); |
| | | }, |
| | | // å
éç¼ç è§åä¿ååè½ |
| | | saveCloneCodeRule(){ |
| | | let form = this.cloneCodeRuleForm; |
| | | if(form.id.trim()==''){ |
| | | this.$message.warning("ç¼å·ä¸è½ä¸ºç©º!"); |
| | | return; |
| | | } |
| | | if(form.name.trim()==''){ |
| | | this.$message.warning("ç å¼ä¸è½ä¸ºç©º!"); |
| | | return; |
| | | } |
| | | this.selectionList[0].oid = ''; |
| | | this.selectionList[0].id = form.id; |
| | | this.selectionList[0].name = form.name; |
| | | this.selectionList[0].description = form.description; |
| | | this.selectionList[0].createTime = new Date().getTime(); |
| | | this.selectionList[0].ts = new Date(this.selectionList[0].ts).getTime(); |
| | | this.selectionList[0].lcStatus = 'Editing'; |
| | | let data = Object.assign({}, this.selectionList[0],{elements:this.cloneData}); |
| | | clone(data).then(() => { |
| | | this.cloneSettingBox = false; |
| | | this.onLoad(this.page); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | //console.log(data); |
| | | }, |
| | | // æå¼ä»å
¶ä»ç¼ç è§åä¸å
éç æ®µå¯¹è¯æ¡ |
| | | openOtherCodeRuleDialog(){ |
| | | if (!this.tipsMessage(this.selectionList)) { |
| | | return; |
| | | } |
| | | if(this.selectionList[0].lcStatus != 'Editing'){ |
| | | this.$message.warning("ç¼ç è§å已被å¼ç¨ï¼ä¸å
许ç¼è¾æå é¤!"); |
| | | return; |
| | | } |
| | | this.cloneOtherCodeRuleSettingBox = true; |
| | | }, |
| | | //åå»ç¼ç è§åå®ç°è¡éæ© |
| | | codeOtherCloneRuleRowClick (row) { |
| | | this.loadBasic(row); |
| | | }, |
| | | // ç¼ç è§åå½åéä¸è¡ååçæ¶å触å |
| | | selectionOtherCloneCodeRuleChange(list) { |
| | | //console.log(list); |
| | | this.selectionOtherCloneCodeRuleList = list; |
| | | if(this.selectionOtherCloneCodeRuleList.length > 0){ |
| | | this.loadBasic(this.selectionOtherCloneCodeRuleList[list.length-1]); |
| | | } |
| | | }, |
| | | selectionOtherCloneCodeBasicChange(list){ |
| | | this.selectionOtherCloneCodeBasicList = list; |
| | | }, |
| | | // ä»å
¶ä»ç¼ç è§åä¸å
éç æ®µä¿¡æ¯ |
| | | saveOtherCodeBasic(){ |
| | | let oid = this.selectionList[0].oid; |
| | | let fromDialogPkCodebasic = this.selectionOtherCloneCodeBasicList; |
| | | if(fromDialogPkCodebasic.length < 0){ |
| | | this.$message.warning("è¯·éæ©ç æ®µæ°æ®!"); |
| | | return; |
| | | } |
| | | let res = fromDialogPkCodebasic.filter((item) => { |
| | | return item.pkCodeRule == oid; |
| | | }); |
| | | if(res != ''){ |
| | | this.$message.warning("éè¦å
éçç¼ç è§åä¸è¢«å
éçç¼ç è§åç¸å!"); |
| | | return; |
| | | } |
| | | //console.log(res); |
| | | let oidArr = ''; |
| | | fromDialogPkCodebasic.forEach((item) =>{ |
| | | oidArr = oidArr+","+item.oid; |
| | | }) |
| | | let data = { |
| | | "pkCodeRule": oid, |
| | | "oidArr": oidArr, |
| | | } |
| | | //console.log(data); |
| | | cloneCodeBasic(data).then(() => { |
| | | this.cloneOtherCodeRuleSettingBox = false; |
| | | this.onLoad(this.page); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }, error => { |
| | | window.console.log(error); |
| | | }); |
| | | }, |
| | | // æ¸
空ç å¼ |
| | | clearAllCodeSec(){ |
| | | if(this.selectionList.length == 0){ |
| | | this.$message.warning("没æéæ©æ°æ®!"); |
| | | return; |
| | | } |
| | | if(this.selectionList.length != 1){ |
| | | this.$message.warning("æ¯æ¬¡åªè½éæ©ä¸æ¡æ°æ®!"); |
| | | return; |
| | | } |
| | | localStorage.setItem("cloneOid",this.selectionList[0].oid) |
| | | this.cloneSettingBox = true; |
| | | let currentData = this.selectionList[0]; |
| | | this.$confirm("ç¡®å®è¦æ¸
空ç å¼ï¼å¦ææ¸
空å°ä¸è½è¢«æ¢å¤ï¼è¯·è°¨æ
ï¼", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }) |
| | | .then(() => { |
| | | let ts = new Date(currentData.ts).getTime(); |
| | | return clearAllCode({"oid": currentData.oid,"ts": ts}); |
| | | }) |
| | | .then(() => { |
| | | this. this.onLoad(this.page); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "æä½æå!" |
| | | }); |
| | | }); |
| | | }, |
| | | |
| | | // æ·»å |
| | | rowSave(row, done, loading) { |
| | | add(row).then(() => { |
| | |
| | | // ç¼ç è§åå½åéä¸è¡ååçæ¶å触å |
| | | selectionChange(list) { |
| | | this.selectionList = list; |
| | | //console.log("selectionChange====="+list); |
| | | this.$refs.crud.setCurrentRow(this.selectionList [list.length-1]); |
| | | if(this.selectionList.length > 0){ |
| | | this.currentCodeRuleOid = this.selectionList[list.length-1].oid; |
| | |
| | | this.loading = false; |
| | | this.loadBasic(this.data[0]) |
| | | this.$nextTick(() => { |
| | | this.$refs.crud.toggleRowSelection(this.data[0]); |
| | | //this.$refs.crud.toggleRowSelection(this.data[0]); |
| | | this.$refs.crud.setCurrentRow(this.data[0]); |
| | | }) |
| | | this.selectionList = data.records[0]; |
| | |
| | | if(condition === 'attr'){ |
| | | this.isShowSelectAttrOption = true; |
| | | }else if(condition === 'value'){ |
| | | this.isShowformulaEdit = true; |
| | | //æå¼å
¬å¼ç¼è¾æ¡ï¼ç¬¬äºå±åµå¥å¯¹è¯æ¡ |
| | | this.$refs.formulaEditor.isShowformulaEdit = true; |
| | | }else if(condition === 'parentClassifySecOid'){ |
| | | this.isShowParentClassifyOption = true; |
| | | }else if(condition === 'referBtmId'){ |
| | |
| | | this.form.referBtmId = ''; |
| | | } |
| | | }, |
| | | |
| | | // è¡¥ä½æ¶çå符ï¼å®ç°å¯è¾å¯é |
| | | inputSelectBlur(e){ |
| | | if (e.target.value) { |
| | | this.form.codeFillSeparatorSelect = e.target.value; |
| | | } |
| | | }, |
| | | // ç æ®µç±»åæ¹åæ¶ï¼å¢å 对åºçform表åä¸ç屿§ |
| | | changeSectypeFormItems(row){ |
| | | console.log(row); |
| | | //console.log(row); |
| | | if(this.sectypeList.length==0){ |
| | | this.loadCodeSecType(); |
| | | } |
| | | if(row != null){ |
| | | this.form = {}; |
| | | this.form = Object.assign({},this.form,{ |
| | | this.form = { |
| | | oid: row.oid, |
| | | id: row.id, //ç¼å·, |
| | | name: row.name,//åç§° |
| | |
| | | componentCodeFlag: row.componentCodeFlag=='true' ? true:false,//æ¯å¦åä¸ç¼ç |
| | | pkCodeRule: row.pkCodeRule, //æå±ç¼ç è§å |
| | | } |
| | | ); |
| | | }else { |
| | | this.form = { |
| | | oid: this.form.oid, |
| | | id: this.form.id, //ç¼å· |
| | | name: this.form.name, //åç§° |
| | | secType: this.form.secType, //ç æ®µç±»å |
| | |
| | | //æµæ°´ç 段 |
| | | this.form = Object.assign({}, this.form,{ |
| | | codeSecLength: row!=null&&row.codeSecLength != '' ? row.codeSecLength:'', //ç æ®µçé¿åº¦ |
| | | serialStart: row!=null&&row.serialStart != '' ? row.serialStart:'1', //æµæ°´å·èµ·å§å¼ |
| | | serialStep: row!=null&&row.serialStep != '' ? row.serialStep:'1', //æµæ°´çæ¥é¿ |
| | | serialStart: row!=null&&row.serialStart != '' ? row.serialStart:1, //æµæ°´å·èµ·å§å¼ |
| | | serialStep: row!=null&&row.serialStep != '' ? row.serialStep:1, //æµæ°´çæ¥é¿ |
| | | codeFillType: row!=null&&row.codeFillType != '' ? row.codeFillType:'code_fill_right', //ç¼ç è¡¥ä½æ¹å¼ |
| | | codeFillSeparatorSelect: row!=null&&row.codeFillSeparatorSelect != '' ? row.codeFillSeparatorSelect:'0', //è¡¥ä½æ¶çå符ï¼éä¸ç䏿æ¡ç䏿 |
| | | codeFillSeparator: row!=null&&row.codeFillSeparator != '' ? row.codeFillSeparator:'0', //è¡¥ä½æ¶çå符 |
| | | codeFillSeparatorSelect: row!=null&&row.codeFillSeparatorSelect != '' ? row.codeFillSeparatorSelect:0, //è¡¥ä½æ¶çå符ï¼éä¸ç䏿æ¡ç䏿 |
| | | codeFillSeparator: row!=null&&row.codeFillSeparator != '' ? row.codeFillSeparator:0, //è¡¥ä½æ¶çå符 |
| | | codeFillLength: row!=null&&row.codeFillLength != '' ? row.codeFillLength:'', //å¡«å
é¿åº¦ |
| | | codeFillLimit: row!=null&&row.codeFillLimit != '' ? row.codeFillLimit:'', //æµæ°´ä¸é |
| | | codeFillFlag: row!=null&&row.codeFillFlag != '' ? row.codeFillFlag=='true' ? true:false :false, //æµæ°´æ¯å¦è¡¥ç |
| | |
| | | codeDateFormatStr: row!=null&&row.codeDateFormatStr != '' ? row.codeDateFormatStr:'', //æ¥ææ ¼å¼ |
| | | }); |
| | | }else if(this.form.secType==='codeclassifysec'){ |
| | | //console.log(this.form); |
| | | //åç±»ç æ®µ |
| | | this.form = Object.assign({}, this.form,{ |
| | | codeSecLengthType: row!=null&&row.codeSecLengthType != '' ? row.codeSecLengthType:'code_sec_length_variable', //ç æ®µé¿åº¦ç±»å |
| | |
| | | this.form = Object.assign({}, this.form,{ |
| | | codeSecLength: row!=null&&row.codeSecLength != '' ? row.codeSecLength:'', //ç æ®µçé¿åº¦ |
| | | codeFillType: row!=null&&row.codeFillType != '' ? row.codeFillType:'code_fill_right', //ç¼ç é¨ä½æ¹å¼ï¼æä¸¾æ¥è¯¢ |
| | | codeFillSeparatorSelect: row!=null&&row.codeFillSeparatorSelect != '' ? row.codeFillSeparatorSelect:'0', //éä¸çè¡¥ä½æ¶çå符ç䏿 |
| | | codeFillSeparatorSelect: row!=null&&row.codeFillSeparatorSelect != '' ? row.codeFillSeparatorSelect:0, //éä¸çè¡¥ä½æ¶çå符ç䏿 |
| | | codeFillSeparator: row!=null&&row.codeFillSeparator != '' ? row.codeFillSeparator:'', //è¡¥ä½æ¶çå符ï¼å¯è¾å¯éæ¥è¯¢ |
| | | }); |
| | | this.loadCodeFillType(); |
| | |
| | | }) |
| | | }, |
| | | |
| | | |
| | | } |
| | | }; |
| | | |
| | | </script> |
| | | |
| | | <style> |
| | | <style scope> |
| | | |
| | | .code-rule-crud > .avue-crud__search ,.code-basic-crud > .avue-crud__search { |
| | | margin-bottom: -15px; |
| | | } |
| | | |
| | | .code-rule-crud > .avue-crud__pagination { |
| | | padding: 14px 0 2px 20px; |
| | | } |
| | | |
| | | |
| | | .clone-input-textarea > .el-form-item__content { |
| | | width: 495px; |
| | | } |
| | | |
| | | .clone-avue-crud > .el-card> .el-card__body > .avue-crud__menu { |
| | | display: none!important; |
| | | } |
| | | |
| | | .fixed-avue-crud > .el-card> .el-card__body > .avue-crud__menu { |
| | | display: none!important; |
| | | } |
| | | |
| | | .other-clone-codebasic-crud > .el-card> .el-card__body > .avue-crud__menu { |
| | | display: none!important; |
| | | } |
| | | |
| | | .other-clone-coderule-crud > .el-card> .el-card__body > .avue-crud__menu { |
| | | display: none!important; |
| | | } |
| | | |
| | | .el-table--small .el-table__cell { |
| | | padding: 3px 0; |
| | | } |
| | | |
| | | .classify_value_box > .el-scrollbar { |
| | | height: 95%; |
| | | } |
| | | |
| | | .basic-container > .el-card > .el-card__body { |
| | | margin: -10px 0; |
| | | } |
| | | .code-basicsec-container{ |
| | | padding: 1px 6px; |
| | | } |
| | | |
| | | .el-divider--horizontal { |
| | | margin-top: 19px !important; |
| | |
| | | |
| | | .el-input-number >.el-input > .el-input__inner { |
| | | width:120px; |
| | | } |
| | | |
| | | .formula-editor{ |
| | | margin-top: -15px; |
| | | margin-left: 2vw; |
| | | /*设置弹æ§çå*/ |
| | | display: flex; |
| | | /*åå
ç´ ä»¥ç«åæåï¼ä¸å
±æ6å*/ |
| | | flex-direction:column; |
| | | width: 360px; |
| | | height: 285px; |
| | | /*å·¦å³ååæå*/ |
| | | justify-content: space-around; |
| | | /*ä¸ä¸ååæå*/ |
| | | align-items: center; |
| | | } |
| | | |
| | | .one{ |
| | | display: flex; |
| | | /*ä»¥è¡æå*/ |
| | | flex-direction: row; |
| | | width: 296px; |
| | | height: 60px; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | } |
| | | |
| | | .formula-editor-btn-sm { |
| | | width: 72px; |
| | | height: 45px; |
| | | background: rgb(153, 214, 240); |
| | | border-radius: 10%; |
| | | } |
| | | |
| | | .el-col>.el-card > .el-card__header { |
| | |
| | | margin-bottom: 8px; |
| | | } |
| | | |
| | | |
| | | </style> |