| | |
| | | <!-- 表格内操作按钮 --> |
| | | <template slot="menu" slot-scope="scope"> |
| | | <el-button v-if="permissionList.editBtn && (scope.row.lcStatus == 'Editing' ? true : false)" |
| | | icon="el-icon-edit" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openEdit(scope.row)" |
| | | >编 辑 |
| | | icon="el-icon-edit" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openEdit(scope.row)" |
| | | >编 辑 |
| | | </el-button> |
| | | <el-button v-if="permissionList.releaseBtn && (scope.row.lcStatus == 'Editing' ? true : false)" |
| | | :loading="releadDisabled" |
| | | icon="el-icon-position" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'release')" |
| | | >发 布 |
| | | :loading="releadDisabled" |
| | | icon="el-icon-position" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'release')" |
| | | >发 布 |
| | | </el-button> |
| | | <el-button v-if="permissionList.deactivateBtn && (scope.row.lcStatus == 'Released' ? true : false)" |
| | | icon="el-icon-video-pause" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'disable')" |
| | | >停 用 |
| | | icon="el-icon-video-pause" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'disable')" |
| | | >停 用 |
| | | </el-button> |
| | | <el-button v-if="permissionList.enableBtn && (scope.row.lcStatus == 'Disabled' ? true : false)" |
| | | icon="el-icon-video-play" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'enable')" |
| | | >启 用 |
| | | icon="el-icon-video-play" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="enableOrDeactivatse(scope.row.oid, 'enable')" |
| | | >启 用 |
| | | </el-button> |
| | | </template> |
| | | <!-- 表格上方按钮区域 --> |
| | | <template slot="menuLeft" slot-scope="scope"> |
| | | <el-button v-if="permissionList.rulDelBtn" |
| | | icon="el-icon-delete" |
| | | plain |
| | | size="small" |
| | | type="danger" |
| | | @click="handleDelete" |
| | | icon="el-icon-delete" |
| | | plain |
| | | size="small" |
| | | type="danger" |
| | | @click="handleDelete" |
| | | > |
| | | 删 除 |
| | | </el-button> |
| | | <el-button v-if="permissionList.advancedQueryBtn" |
| | | icon="el-icon-search" |
| | | plain |
| | | size="small" |
| | | type="primary" |
| | | @click="openAdvancedQuery('codeRule')"> |
| | | icon="el-icon-search" |
| | | plain |
| | | size="small" |
| | | type="primary" |
| | | @click="openAdvancedQuery('codeRule')"> |
| | | 高级查询 |
| | | </el-button> |
| | | <el-button v-if="permissionList.cloneBtn" |
| | | icon="icon-kelong" |
| | | plain |
| | | size="small" |
| | | @click="openCodeRuleDialog" |
| | | icon="icon-kelong" |
| | | plain |
| | | size="small" |
| | | @click="openCodeRuleDialog" |
| | | > |
| | | 克 隆 |
| | | </el-button> |
| | | <el-button v-if="permissionList.otherCloneBtn" |
| | | icon="icon-lianjiekelong" |
| | | plain |
| | | size="small" |
| | | style="font-size: 12px" |
| | | @click="openOtherCodeRuleDialog" |
| | | icon="icon-lianjiekelong" |
| | | plain |
| | | size="small" |
| | | style="font-size: 12px" |
| | | @click="openOtherCodeRuleDialog" |
| | | > |
| | | 从其他规则中克隆码段 |
| | | </el-button> |
| | | <el-button v-if="permissionList.usescopeBtn" |
| | | icon="el-icon-s-help" |
| | | plain |
| | | size="small" |
| | | @click="handleRange" |
| | | icon="el-icon-s-help" |
| | | plain |
| | | size="small" |
| | | @click="handleRange" |
| | | > |
| | | 使用范围 |
| | | </el-button> |
| | | <el-button v-if="permissionList.clearBtn" |
| | | icon="icon-qingkong" |
| | | plain |
| | | size="small" |
| | | @click="clearAllCodeSec" |
| | | icon="icon-qingkong" |
| | | plain |
| | | size="small" |
| | | @click="clearAllCodeSec" |
| | | > |
| | | 清空码值 |
| | | </el-button> |
| | | <el-button v-if="permissionList.escapeOwnerBtn" |
| | | icon="el-icon-guide" |
| | | plain |
| | | size="small" |
| | | @click="escapeOwner" |
| | | <el-button v-if="permissionList.escapeOwnerBtn" |
| | | icon="el-icon-guide" |
| | | plain |
| | | size="small" |
| | | @click="escapeOwner" |
| | | > |
| | | 转移所有者 |
| | | </el-button> |
| | | <el-button v-if="permissionList.maxSerialnumBtn" |
| | | icon="el-icon-data-analysis" |
| | | plain |
| | | size="small" |
| | | @click="maxSerialNum" |
| | | <el-button v-if="permissionList.maxSerialnumBtn" |
| | | icon="el-icon-data-analysis" |
| | | plain |
| | | size="small" |
| | | @click="maxSerialNum" |
| | | > |
| | | 最大流水号 |
| | | </el-button> |
| | |
| | | |
| | | <!-- 编码规则,克隆对话框 --> |
| | | <clone-rule-dialog |
| | | :visible.sync="cloneSettingBox" |
| | | :ruleData="selectionList[0]" |
| | | :visible.sync="cloneSettingBox" |
| | | @refreshRuleTable="onLoad"> |
| | | </clone-rule-dialog> |
| | | |
| | | <!-- 编码规则,从其他规则克隆对话框 --> |
| | | <clone-other-basic-sec-dialog |
| | | :visible.sync="cloneOtherCodeRuleSettingBox" |
| | | :quiltCloneCodeRule="selectionList[0]" |
| | | :visible.sync="cloneOtherCodeRuleSettingBox" |
| | | @refreshRuleTable="onLoad"> |
| | | </clone-other-basic-sec-dialog> |
| | | |
| | |
| | | <el-dialog |
| | | :visible.sync="escapeOwnerVisible" |
| | | append-to-body |
| | | class="avue-dialog avue-dialog--top" |
| | | title="转移所有者" |
| | | width="30%" |
| | | class= "avue-dialog avue-dialog--top" |
| | | > |
| | | <el-select v-model="ruleOwner" class="selects" placeholder="请选择"> |
| | | <el-option |
| | |
| | | <!-- 基础码段表格内操作按钮 --> |
| | | <template slot="menu" slot-scope="scope"> |
| | | <el-button v-if="basicPermissionList.viewBtn && currentRuleLcStatus != 'Editing'" |
| | | icon="el-icon-view" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openBasicDialog('view', scope.row)" |
| | | >查看 |
| | | icon="el-icon-view" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openBasicDialog('view', scope.row)" |
| | | >查看 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.editBtn && currentRuleLcStatus === 'Editing'" |
| | | icon="el-icon-edit" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openBasicDialog('edit', scope.row)" |
| | | >编辑 |
| | | icon="el-icon-edit" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openBasicDialog('edit', scope.row)" |
| | | >编辑 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicMgrBtn && (scope.row.secType === 'codeclassifysec' || scope.row.secType == 'codefixedsec')" |
| | | <el-button |
| | | v-if="basicPermissionList.basicMgrBtn && (scope.row.secType === 'codeclassifysec' || scope.row.secType == 'codefixedsec')" |
| | | icon="el-icon-setting" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="openBasicSecCodeValueMgr(scope.row)" |
| | | >码值管理 |
| | | >码值管理 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicMoveupBtn && scope.row.orderNum > 1" |
| | | icon="el-icon-arrow-up" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="upOrderNum(scope.row)" |
| | | >上移 |
| | | icon="el-icon-arrow-up" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="upOrderNum(scope.row)" |
| | | >上移 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicDownBtn" |
| | | icon="el-icon-arrow-down" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="downOrderNum(scope.row)" |
| | | >下移 |
| | | icon="el-icon-arrow-down" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="downOrderNum(scope.row)" |
| | | >下移 |
| | | </el-button> |
| | | </template> |
| | | |
| | | <!-- 基础码段表格左上方按钮区域 --> |
| | | <template slot="menuLeft" slot-scope="scope"> |
| | | <el-button v-if="basicPermissionList.addBtn" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-plus" |
| | | size="small" |
| | | type="primary" |
| | | @click="openAddBasicCodeSec" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-plus" |
| | | size="small" |
| | | type="primary" |
| | | @click="openAddBasicCodeSec" |
| | | > |
| | | 新 增 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicDelBtn" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-delete" |
| | | plain |
| | | size="small" |
| | | type="danger" |
| | | @click="deleteBasicCode(scope.row)" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-delete" |
| | | plain |
| | | size="small" |
| | | type="danger" |
| | | @click="deleteBasicCode(scope.row)" |
| | | > |
| | | 删 除 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicAdvancedQueryBtn" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-search" |
| | | plain |
| | | size="small" |
| | | type="primary" |
| | | @click="openAdvancedQuery('codeBasicSec')" |
| | | <el-button v-if="basicPermissionList.basicAdvancedQueryBtn" |
| | | :disabled="selectionList.length <= 0" |
| | | icon="el-icon-search" |
| | | plain |
| | | size="small" |
| | | type="primary" |
| | | @click="openAdvancedQuery('codeBasicSec')" |
| | | > |
| | | 高级查询 |
| | | </el-button> |
| | |
| | | size="mini" |
| | | type="primary" |
| | | @click="codeClassifyValueOpetion('up')" |
| | | >上移 |
| | | >上移 |
| | | </el-button> |
| | | <el-button |
| | | class="button" |
| | |
| | | size="mini" |
| | | type="primary" |
| | | @click="codeClassifyValueOpetion('down')" |
| | | >下移 |
| | | >下移 |
| | | </el-button> |
| | | </div> |
| | | </basic-container> |
| | |
| | | size="mini" |
| | | type="primary" |
| | | @click="addCodeSecValue('codeclassifyvaluesec')" |
| | | >添加 |
| | | >添加 |
| | | </el-button> |
| | | <el-button |
| | | :disabled="selectedFixedOrCodeclassifyValue == ''" |
| | |
| | | size="mini" |
| | | type="success" |
| | | @click="editCodeSecValue('codeclassifyvaluesec')" |
| | | >修改 |
| | | >修改 |
| | | </el-button> |
| | | <el-button |
| | | :disabled="selectedFixedOrCodeclassifyValue == ''" |
| | |
| | | size="mini" |
| | | type="danger" |
| | | @click="delCodeSecValue('codeclassifyvaluesec')" |
| | | >删除 |
| | | >删除 |
| | | </el-button> |
| | | <el-button |
| | | class="button" |
| | |
| | | size="mini" |
| | | type="warning" |
| | | @click="clearFixedOrClassifyForm('codeclassifyvaluesec')" |
| | | >取消 |
| | | >取消 |
| | | </el-button> |
| | | </div> |
| | | </basic-container> |
| | |
| | | size="mini" |
| | | type="text" |
| | | @click="codeFixedValueOpetion('up', scope.row)" |
| | | >上移 |
| | | >上移 |
| | | </el-button> |
| | | <el-button |
| | | icon="el-icon-arrow-down" |
| | | size="mini" |
| | | type="text" |
| | | @click="codeFixedValueOpetion('down', scope.row)" |
| | | >下移 |
| | | >下移 |
| | | </el-button> |
| | | <el-button |
| | | icon="el-icon-minus" |
| | | size="mini" |
| | | type="text" |
| | | @click="codeFixedValueOpetion('remove', scope.row)" |
| | | >移除 |
| | | >移除 |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | |
| | | size="mini" |
| | | type="primary" |
| | | @click="saveCodeFixedOrClassifyValueOption('fixedValue')" |
| | | >保存 |
| | | >保存 |
| | | </el-button> |
| | | </div> |
| | | </basic-container> |
| | |
| | | size="mini" |
| | | type="primary" |
| | | @click="addCodeSecValue('codefixedsec')" |
| | | >添加 |
| | | >添加 |
| | | </el-button> |
| | | <el-button |
| | | :disabled="selectedFixedOrCodeclassifyValue == ''" |
| | |
| | | size="mini" |
| | | type="success" |
| | | @click="editCodeSecValue('codefixedsec')" |
| | | >修改 |
| | | >修改 |
| | | </el-button> |
| | | <el-button |
| | | :disabled="selectedFixedOrCodeclassifyValue == ''" |
| | |
| | | size="mini" |
| | | type="danger" |
| | | @click="delCodeSecValue('codefixedsec')" |
| | | >删除 |
| | | >删除 |
| | | </el-button> |
| | | <el-button |
| | | class="button" |
| | |
| | | size="mini" |
| | | type="warning" |
| | | @click="clearFixedOrClassifyForm('codefixedsec')" |
| | | >取消 |
| | | >取消 |
| | | </el-button> |
| | | </div> |
| | | </basic-container> |
| | |
| | | :label-width="rightFormLabelWidth" |
| | | label="自定义的流水算法:" |
| | | > |
| | | <el-input |
| | | v-model="form.customCodeSerialClass" |
| | | :readonly="basicSecOnlyRead" |
| | | ></el-input> |
| | | <template> |
| | | <vciWebRefer |
| | | ref="refer" |
| | | :referConfig="this.referConfig || {}" |
| | | :display="true" |
| | | :value="form.customCodeSerialClass" |
| | | :text="form.customCodeSerialClass" |
| | | @setReferValue="setReferValue" |
| | | ></vciWebRefer> |
| | | <!-- <el-input--> |
| | | <!-- v-model="form.customCodeSerialClass"--> |
| | | <!-- :readonly="basicSecOnlyRead"--> |
| | | <!-- @focus="streamFocusHandler"--> |
| | | <!-- ></el-input>--> |
| | | </template> |
| | | |
| | | |
| | | </el-form-item> |
| | | </div> |
| | | <!-- 层级码段 --> |
| | |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button |
| | | :disabled="!showbtn" |
| | | type="primary" |
| | | :loading="isLoadingSecCodeAddBtn" |
| | | @click="saveOrEditBasicCode">保 存</el-button> |
| | | type="primary" |
| | | @click="saveOrEditBasicCode">保 存 |
| | | </el-button> |
| | | <el-button @click="addBasicCodeSettingBox = false">取 消</el-button> |
| | | </div> |
| | | |
| | |
| | | </avue-crud> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="saveSelectedParentClassify" |
| | | >保 存</el-button |
| | | >保 存 |
| | | </el-button |
| | | > |
| | | <el-button |
| | | @click="parentClsfyParams.isShowParentClassifySettingBox = false" |
| | | >取 消</el-button |
| | | >取 消 |
| | | </el-button |
| | | > |
| | | </div> |
| | | </el-dialog> |
| | |
| | | > |
| | | </refer-config-dialog> |
| | | </el-dialog> |
| | | |
| | | <!-- 自定义流水参照组件--> |
| | | |
| | | |
| | | </basic-container> |
| | | </template> |
| | | |
| | |
| | | addSave, |
| | | refDataGridClassifySec, |
| | | } from "@/api/code/codebasic"; |
| | | import { listClassifyLinkAttr } from "@/api/code/codeclassify"; |
| | | import {listClassifyLinkAttr} from "@/api/code/codeclassify"; |
| | | import { |
| | | gridCodeFixedValue, |
| | | addSaveCodeFixedValue, |
| | |
| | | deleteCodeClassifyValue, |
| | | saveCodeClassifyValueOrder, |
| | | } from "@/api/code/codeClassifyValue"; |
| | | import { getDictionary } from "@/api/omd/enum"; |
| | | import { getDictionaryBiz } from "@/api/system/dictbiz"; |
| | | import {getDictionary} from "@/api/omd/enum"; |
| | | import {getDictionaryBiz} from "@/api/system/dictbiz"; |
| | | import optionBasic from "@/const/code/codebasic"; |
| | | import optionRule from "@/const/code/mdmrule"; |
| | | import attrOption from "@/const/code/selectAttrOptionDialog"; |
| | |
| | | import classisyValueTreeOption from "@/const/code/classisyValueTreeDialog"; |
| | | import parentClassifyParentOption from "@/const/code/parentClassifyParentOptionDialog"; |
| | | import fixedValueOption from "@/const/code/fixedValueMgrDialog"; |
| | | import { mapGetters } from "vuex"; |
| | | import { getByRoleUserList } from "@/api/system/user"; |
| | | import {mapGetters} from "vuex"; |
| | | import {getByRoleUserList} from "@/api/system/user"; |
| | | import func from "@/util/func"; |
| | | import secTypeEnum from '@/enumpack/CodeSecTypeEnum'; |
| | | import vciWebRefer from "../../components/refer/vciWebRefer"; |
| | | |
| | | export default { |
| | | components: { vciWebRefer }, |
| | | data() { |
| | | return { |
| | | crudOption:{...optionRule}, |
| | | referConfig:{ |
| | | title: '自定义流水参照', |
| | | showField: 'customCodeSerialClass', |
| | | field: 'customCodeSerialClass', |
| | | fieldMap: {}, |
| | | placeholder:'请选择自定义流水', |
| | | options: { |
| | | // 设置默认的属性 |
| | | url: 'api/ubcs-code/codeSerialAlgorithmController/gridCodeSerialAlgorithm', |
| | | valueField:'classFullName', |
| | | textField:'classFullName', |
| | | isMuti: false, |
| | | type: "grid", |
| | | method: 'get', |
| | | tableConfig: { |
| | | page: { |
| | | limit: 15, |
| | | page: 1 |
| | | }, |
| | | cols: [ |
| | | {title: '算法编号', field: 'id', width: 200}, |
| | | {title: '算法名称', field: 'name', width: 150}, |
| | | {title: '类全路径', field: 'classFullName', width: 300}, |
| | | {title: '描述', field: 'description'} |
| | | ], |
| | | queryColumns: [ |
| | | {field: 'id', title: '算法编号'}, |
| | | {field: 'name', title: '算法名称'} |
| | | ] |
| | | } |
| | | } |
| | | }, |
| | | crudOption: {...optionRule}, |
| | | ruleForm: {}, |
| | | query: {}, |
| | | loading: true, |
| | |
| | | editBtn: this.vaildData(this.permission.code_rule.code_rule_edit, false), |
| | | deactivateBtn: this.vaildData(this.permission.code_rule.code_rule_deactivate, false), |
| | | enableBtn: this.vaildData(this.permission.code_rule.code_rule_enable, false), |
| | | releaseBtn: this.vaildData(this.permission.code_rule. code_rule_release, false), |
| | | releaseBtn: this.vaildData(this.permission.code_rule.code_rule_release, false), |
| | | advancedQueryBtn: this.vaildData(this.permission.code_rule.code_rule_advanced_query, false), |
| | | cloneBtn: this.vaildData(this.permission.code_rule.code_rule_clone, false), |
| | | otherCloneBtn: this.vaildData(this.permission.code_rule.code_rule_other_clone, false), |
| | |
| | | }; |
| | | }, |
| | | basicPermissionList() { |
| | | return{ |
| | | return { |
| | | // 基础码段相关按钮 |
| | | addBtn: this.vaildData(this.permission.code_rule.code_basic_add, false), |
| | | editBtn: this.vaildData(this.permission.code_rule.code_basic_edit, false), |
| | | viewBtn: this.vaildData(this.permission.code_rule. code_basic_view, false), |
| | | viewBtn: this.vaildData(this.permission.code_rule.code_basic_view, false), |
| | | basicDelBtn: this.vaildData(this.permission.code_rule.code_basic_delete, false), |
| | | basicAdvancedQueryBtn: this.vaildData(this.permission.code_rule.code_basic_advanced_query, false), |
| | | basicMgrBtn: this.vaildData(this.permission.code_rule.code_basic_mgr, false), |
| | |
| | | localStorage.removeItem('codeGetValueType'); |
| | | }, |
| | | methods: { |
| | | |
| | | //自定义流水失焦 |
| | | setReferValue(data){ |
| | | console.log(data) |
| | | }, |
| | | /** 转移规则所有者对话框 */ |
| | | escapeOwner() { |
| | | if (this.selectionList.length === 0) { |
| | |
| | | /** 加载固定码段码值表数据*/ |
| | | loadFixedValueTableData(row) { |
| | | this.fixedValueOptionLoading = true; |
| | | gridCodeFixedValue(1, -1, { codeFixedSecOid: row.oid }).then((res) => { |
| | | gridCodeFixedValue(1, -1, {codeFixedSecOid: row.oid}).then((res) => { |
| | | this.fixedValueData = res.data.data.records; |
| | | this.fixedValueOptionLoading = false; |
| | | }); |
| | |
| | | description: this.codeFixdForm.description, |
| | | id: this.codeFixdForm.id, |
| | | codeFixedSecOid: |
| | | this.selectedFixedOrCodeclassifyValue.codefixedsecoid, |
| | | this.selectedFixedOrCodeclassifyValue.codefixedsecoid, |
| | | }; |
| | | editCodeFixedValue(editData).then( |
| | | () => { |
| | |
| | | }, |
| | | /** 修改规则状态:启用、停用、发布 */ |
| | | updateStatus(oid, update) { |
| | | updateStatus({ oid: oid, ts: new Date().getTime, update: update }).then( |
| | | updateStatus({oid: oid, ts: new Date().getTime, update: update}).then( |
| | | () => { |
| | | this.releadDisabled = false; |
| | | this.onLoad(this.page); |
| | |
| | | //console.log(res) |
| | | if (res.data.data.success) { |
| | | this.updateStatus(oid, update); |
| | | }else { |
| | | } else { |
| | | this.$confirm(res.data.data.msg, "提示", { |
| | | distinguishCancelAndClose: true, |
| | | confirmButtonText: "继续发布", |
| | |
| | | }) |
| | | .then(() => { |
| | | let ts = new Date(currentData.ts).getTime(); |
| | | return clearAllCode({ oid: currentData.oid, ts: ts }); |
| | | return clearAllCode({oid: currentData.oid, ts: ts}); |
| | | }) |
| | | .then(() => { |
| | | this.this.onLoad(this.page); |
| | |
| | | // 只支持每次单条记录删除 |
| | | let oid = this.selectionList[0].oid; |
| | | let ts = new Date(this.selectionList[0].ts).getTime(); |
| | | return remove({ oid: oid, ts: ts }); |
| | | return remove({oid: oid, ts: ts}); |
| | | }) |
| | | .then(() => { |
| | | this.onLoad(this.page); |
| | |
| | | gridCodeRule( |
| | | page.currentPage, |
| | | page.pageSize, |
| | | Object.assign({},params,this.query), |
| | | Object.assign({}, params, this.query), |
| | | ).then((res) => { |
| | | //console.log(res.data); |
| | | const data = res.data.data; |
| | |
| | | let oldBasicSec = this.selectionBasicList.at(-1); |
| | | let secType = this.form.secType; |
| | | Vue.set(this.form, 'isClearValue', false); |
| | | if((oldBasicSec.secType == "codefixedsec" || oldBasicSec.secType === "codeclassifysec") && oldBasicSec.secType != secType){ |
| | | await this.$confirm("码段类型由【"+oldBasicSec.secTypeText+"】,修改为"+"【"+secTypeEnum.getTextByValue(secType)+"】,请问是否需要清空关联的码值?", "提示", { |
| | | if ((oldBasicSec.secType == "codefixedsec" || oldBasicSec.secType === "codeclassifysec") && oldBasicSec.secType != secType) { |
| | | await this.$confirm("码段类型由【" + oldBasicSec.secTypeText + "】,修改为" + "【" + secTypeEnum.getTextByValue(secType) + "】,请问是否需要清空关联的码值?", "提示", { |
| | | distinguishCancelAndClose: true, |
| | | closeOnClickModal: false, |
| | | confirmButtonText: "清空码值", |
| | |
| | | }) |
| | | .then(() => { |
| | | let ts = new Date(this.selectionBasicList[0].ts).getTime(); |
| | | return deleteData({ oid: oid, ts: ts }); |
| | | return deleteData({oid: oid, ts: ts}); |
| | | }) |
| | | .then(() => { |
| | | this.loadBasic({ |
| | |
| | | //存储当前关联的编码规则相关信息 |
| | | this.currentCodeRuleOid = row.oid; |
| | | this.currentRuleLcStatus = row.lcStatus; |
| | | this.sendGridCodeBasicSec({ pkCodeRule: row.oid }, false); |
| | | this.sendGridCodeBasicSec({pkCodeRule: row.oid}, false); |
| | | } |
| | | }, |
| | | /** 发送加载基础码段的请求*/ |
| | |
| | | }, |
| | | basicSearchReset() { |
| | | this.sendGridCodeBasicSec( |
| | | { pkCodeRule: this.selectionList[this.selectionList.length - 1].oid }, |
| | | {pkCodeRule: this.selectionList[this.selectionList.length - 1].oid}, |
| | | false |
| | | ); |
| | | }, |
| | |
| | | return; |
| | | } |
| | | downOrderNum(row.oid).then(() => { |
| | | this.loadBasic({ oid: codeRuleOid }); |
| | | this.loadBasic({oid: codeRuleOid}); |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | |
| | | this.loadCodeSecType(); |
| | | } |
| | | this.form = { |
| | | oid: row !=null ? row.oid:this.form.oid, |
| | | id: row != null ? row.id:this.form.id, //编号, |
| | | name: row != null ? row.name:this.form.name, //名称 |
| | | secType: row != null ? row.secType:this.form.secType, //码段类型 |
| | | description: row != null ? row.description:this.form.description, //描述 |
| | | serialDependFlag: this.isNullJsonBoolean(row,this.form, 'serialDependFlag'), //是否流水依赖 |
| | | serialDependOrder: row !=null ? row.serialDependOrder:this.form.serialDependOrder, //流水依赖顺序 |
| | | oid: row != null ? row.oid : this.form.oid, |
| | | id: row != null ? row.id : this.form.id, //编号, |
| | | name: row != null ? row.name : this.form.name, //名称 |
| | | secType: row != null ? row.secType : this.form.secType, //码段类型 |
| | | description: row != null ? row.description : this.form.description, //描述 |
| | | serialDependFlag: this.isNullJsonBoolean(row, this.form, 'serialDependFlag'), //是否流水依赖 |
| | | serialDependOrder: row != null ? row.serialDependOrder : this.form.serialDependOrder, //流水依赖顺序 |
| | | nullableFlag: this.isNullJsonBoolean(row, this.form, 'nullableFlag'), //是否为空 |
| | | displayFlag: this.isNullJsonBoolean(row, this.form, 'displayFlag'), |
| | | componentCodeFlag: this.isNullJsonBoolean(row, this.form, 'componentCodeFlag'), //是否参与编码 |
| | | pkCodeRule: row != null ? row.pkCodeRule:this.form.pkCodeRule, //所属编码规则 |
| | | prefixCode: row != null ? row.prefixCode:this.form.prefixCode, //前缀 |
| | | suffixCode: row!= null ? row.suffixCode:this.form.suffixCode, //后缀 |
| | | pkCodeRule: row != null ? row.pkCodeRule : this.form.pkCodeRule, //所属编码规则 |
| | | prefixCode: row != null ? row.prefixCode : this.form.prefixCode, //前缀 |
| | | suffixCode: row != null ? row.suffixCode : this.form.suffixCode, //后缀 |
| | | }; |
| | | if (this.form.secType === "codefixedsec") { |
| | | //固定码段 |
| | |
| | | row != null && row.serialStart != "" ? row.serialStart : 1, //流水号起始值 |
| | | serialStep: row != null && row.serialStep != "" ? row.serialStep : 1, //流水的步长 |
| | | codeFillType: row != null && row.codeFillType != "" |
| | | ? row.codeFillType |
| | | : "code_fill_left", //编码补位方式 |
| | | ? row.codeFillType |
| | | : "code_fill_left", //编码补位方式 |
| | | // codeFillSeparatorSelect: row!=null&&row.codeFillSeparatorSelect != '' ? row.codeFillSeparatorSelect:0, //补位时的字符,选中的下拉框的下标 |
| | | codeFillSeparator: |
| | | row != null && row.codeFillSeparator != "" |
| | |
| | | codeFillFlag: |
| | | row != null && row.codeFillFlag != "" |
| | | ? row.codeFillFlag == "true" |
| | | ? true |
| | | : false |
| | | ? true |
| | | : false |
| | | : false, //流水是否补码 |
| | | customCodeSerialClass: |
| | | row != null && row.customCodeSerialClass != "" |
| | |
| | | matchClassifyValueFlag: |
| | | row != null && row.matchClassifyValueFlag != "" |
| | | ? row.matchClassifyValueFlag == "true" |
| | | ? true |
| | | : false |
| | | ? true |
| | | : false |
| | | : false, //是否自动匹配值 |
| | | parentClassifySecOid: |
| | | row != null && row.parentClassifySecOid != "" |
| | |
| | | } |
| | | }, |
| | | // 判断Boolean值是否为空,并且对str类型布尔值进行转换 |
| | | isNullJsonBoolean(row,form,attr) { |
| | | //console.log(row[attr],form[attr]); |
| | | if(row != null){ |
| | | return JSON.parse(row[attr]); |
| | | }else { |
| | | return form[attr]; |
| | | } |
| | | isNullJsonBoolean(row, form, attr) { |
| | | //console.log(row[attr],form[attr]); |
| | | if (row != null) { |
| | | return JSON.parse(row[attr]); |
| | | } else { |
| | | return form[attr]; |
| | | } |
| | | }, |
| | | /** 第一次请求的枚举数据放缓存*/ |
| | | getLocalStorageEnum(enumKey) { |
| | | let enumCach = JSON.parse(localStorage.getItem(enumKey)); |
| | | if (enumCach == null) { |
| | | getDictionary({ code: enumKey }).then((res) => { |
| | | getDictionary({code: enumKey}).then((res) => { |
| | | enumCach = res.data.data; |
| | | localStorage.setItem(enumKey, JSON.stringify(res.data.data)); |
| | | }); |
| | |
| | | loadCodeFillSeparator() { |
| | | //let enumCach = JSON.parse(localStorage.getItem("codeFillSeparator")); |
| | | //if (enumCach == null) { |
| | | getDictionaryBiz({code:"codeFillSeparator"}).then((res) => { |
| | | getDictionaryBiz({code: "codeFillSeparator"}).then((res) => { |
| | | this.enumParam.codeFillSeparator = res.data.data; |
| | | //console.log(this.enumParam.codeFillSeparator); |
| | | localStorage.setItem( |
| | |
| | | this.$message.warning("请选择一条编码规则!"); |
| | | return; |
| | | } |
| | | if(this.selectionList.length> 1){ |
| | | if (this.selectionList.length > 1) { |
| | | this.$message.warning("只能选择一条编码规则!"); |
| | | return; |
| | | } |
| | |
| | | </script> |
| | | |
| | | <style> |
| | | [class^="icon-"] { |
| | | font-size: 12px !important; |
| | | } |
| | | [class^="icon-"] { |
| | | font-size: 12px !important; |
| | | } |
| | | |
| | | .code-rule-crud > .avue-crud__search, |
| | | .code-basic-crud > .avue-crud__search { |
| | | margin-bottom: -15px; |
| | | } |
| | | .code-rule-crud > .avue-crud__search, |
| | | .code-basic-crud > .avue-crud__search { |
| | | margin-bottom: -15px; |
| | | } |
| | | |
| | | .clone-input-textarea > .el-form-item__content { |
| | | width: 495px; |
| | | } |
| | | .clone-input-textarea > .el-form-item__content { |
| | | width: 495px; |
| | | } |
| | | |
| | | .clone-avue-crud > .el-card > .el-card__body > .avue-crud__menu { |
| | | display: none !important; |
| | | } |
| | | .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; |
| | | } |
| | | .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-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; |
| | | } |
| | | .other-clone-coderule-crud > .el-card > .el-card__body > .avue-crud__menu { |
| | | display: none !important; |
| | | } |
| | | |
| | | .el-table--small .el-table__cell { |
| | | padding: 3px 0; |
| | | } |
| | | .el-table--small .el-table__cell { |
| | | padding: 3px 0; |
| | | } |
| | | |
| | | .classify_value_box > .el-scrollbar { |
| | | height: 95%; |
| | | } |
| | | .classify_value_box > .el-scrollbar { |
| | | height: 95%; |
| | | } |
| | | |
| | | .basic-container > .el-card > .el-card__body { |
| | | margin: -10px 0; |
| | | } |
| | | .basic-container > .el-card > .el-card__body { |
| | | margin: -10px 0; |
| | | } |
| | | |
| | | .code-basicsec-container { |
| | | padding: 1px 6px; |
| | | } |
| | | .code-basicsec-container { |
| | | padding: 1px 6px; |
| | | } |
| | | |
| | | .horizontal-line { |
| | | /* margin-top: 19px !important; */ |
| | | margin-bottom: -20px !important; |
| | | width: 100%; |
| | | height: 2px; |
| | | } |
| | | .horizontal-line { |
| | | /* margin-top: 19px !important; */ |
| | | margin-bottom: -20px !important; |
| | | width: 100%; |
| | | height: 2px; |
| | | } |
| | | |
| | | .el-card__body > .treeBox { |
| | | height: 56vh; |
| | | } |
| | | .el-card__body > .treeBox { |
| | | height: 56vh; |
| | | } |
| | | |
| | | .el-col-5 > .box { |
| | | height: 56vh; |
| | | } |
| | | .el-col-5 > .box { |
| | | height: 56vh; |
| | | } |
| | | |
| | | .operator_, |
| | | filter, |
| | | .layui-btn { |
| | | width: 60px; |
| | | } |
| | | .operator_, |
| | | filter, |
| | | .layui-btn { |
| | | width: 60px; |
| | | } |
| | | |
| | | .left > .el-form-item > .el-form-item__content > .el-input-number { |
| | | width: 120px; |
| | | } |
| | | .left > .el-form-item > .el-form-item__content > .el-input-number { |
| | | width: 120px; |
| | | } |
| | | |
| | | .left |
| | | > .el-form-item |
| | | > .el-form-item__content |
| | | > .el-input-number |
| | | > .el-input |
| | | > .el-input__inner { |
| | | width: 120px; |
| | | } |
| | | .left |
| | | > .el-form-item |
| | | > .el-form-item__content |
| | | > .el-input-number |
| | | > .el-input |
| | | > .el-input__inner { |
| | | width: 120px; |
| | | } |
| | | |
| | | .el-col > .el-card > .el-card__header { |
| | | background: rgb(213 231 239); |
| | | border-radius: inherit; |
| | | } |
| | | .el-col > .el-card > .el-card__header { |
| | | background: rgb(213 231 239); |
| | | border-radius: inherit; |
| | | } |
| | | |
| | | /** 新增码段 */ |
| | | .add-basicsec-dialog > .el-dialog > .el-dialog__body { |
| | | padding: 20px 20px 4px; |
| | | margin-bottom: 30px; |
| | | } |
| | | /** 新增码段 */ |
| | | .add-basicsec-dialog > .el-dialog > .el-dialog__body { |
| | | padding: 20px 20px 4px; |
| | | margin-bottom: 30px; |
| | | } |
| | | |
| | | .add-basicsec-total { |
| | | width: 100%; |
| | | height: 500px; |
| | | } |
| | | .add-basicsec-total { |
| | | width: 100%; |
| | | height: 500px; |
| | | } |
| | | |
| | | .add-basicsec-total .el-input__inner, |
| | | .add-basicsec-total .el-textarea__inner { |
| | | width: 220px; |
| | | } |
| | | .add-basicsec-total .el-input__inner, |
| | | .add-basicsec-total .el-textarea__inner { |
| | | width: 220px; |
| | | } |
| | | |
| | | .add-basicsec-total > .add-basicsec-form { |
| | | display: flex; |
| | | flex-direction: row; |
| | | width: 100%; |
| | | .add-basicsec-total > .add-basicsec-form { |
| | | display: flex; |
| | | flex-direction: row; |
| | | width: 100%; |
| | | height: 100%; |
| | | align-items: center; |
| | | justify-content: space-around; |
| | | } |
| | | |
| | | .add-basicsec-form > .el-divider--vertical { |
| | | width: 2px; |
| | | height: 78%; |
| | | position: absolute; |
| | | top: 50%; |
| | | left: 50%; |
| | | transform: translate(-50%, -50%); |
| | | } |
| | | |
| | | .left { |
| | | /* float: left; */ |
| | | width: 45%; |
| | | height: 100%; |
| | | } |
| | | |
| | | .right { |
| | | /* float: right; */ |
| | | margin-right: 2vw; |
| | | height: 100%; |
| | | width: auto; |
| | | } |
| | | |
| | | .add-basicsec-form > .left > .el-form-item, |
| | | .add-basicsec-form > .right > div > .el-form-item { |
| | | margin-bottom: 12px; |
| | | } |
| | | |
| | | /* 对话框底部按钮边框样式 */ |
| | | .el-dialog__footer { |
| | | /* width: 100%; */ |
| | | border-top: 1px solid #e9e7e7; |
| | | padding: 5px 10px 10px; |
| | | } |
| | | |
| | | .seloption { |
| | | margin-left: 10px; |
| | | } |
| | | |
| | | /* .code-total > .basic-container__card { |
| | | height: 100%; |
| | | align-items: center; |
| | | justify-content: space-around; |
| | | } |
| | | |
| | | .add-basicsec-form > .el-divider--vertical { |
| | | width: 2px; |
| | | height: 78%; |
| | | position: absolute; |
| | | top: 50%; |
| | | left: 50%; |
| | | transform: translate(-50%, -50%); |
| | | } |
| | | |
| | | .left { |
| | | /* float: left; */ |
| | | width: 45%; |
| | | height: 100%; |
| | | } |
| | | |
| | | .right { |
| | | /* float: right; */ |
| | | margin-right: 2vw; |
| | | height: 100%; |
| | | width: auto; |
| | | } |
| | | |
| | | .add-basicsec-form > .left > .el-form-item, |
| | | .add-basicsec-form > .right > div > .el-form-item{ |
| | | margin-bottom: 12px; |
| | | } |
| | | |
| | | /* 对话框底部按钮边框样式 */ |
| | | .el-dialog__footer { |
| | | /* width: 100%; */ |
| | | border-top: 1px solid #e9e7e7; |
| | | padding: 5px 10px 10px; |
| | | } |
| | | |
| | | .seloption { |
| | | margin-left: 10px; |
| | | } |
| | | |
| | | /* .code-total > .basic-container__card { |
| | | height: 100%; |
| | | } */ |
| | | } */ |
| | | |
| | | </style> |