| | |
| | | |
| | | <!-- 基础码段展示区域 --> |
| | | <basic-container class="code-basicsec-container"> |
| | | <div style="height: 38.5vh;overflow: auto"> |
| | | <p |
| | | style="margin-top: -5px; |
| | | <div style="height: 38.5vh;overflow: auto"> |
| | | <p |
| | | style="margin-top: -5px; |
| | | margin-bottom: 4px; |
| | | font-weight: 570; |
| | | font-size: 19px; |
| | | color: #0e2d5f;"> |
| | | 码段管理 |
| | | </p> |
| | | <avue-crud |
| | | ref="crudBasic" |
| | | :data="basicData" |
| | | :option="optionBasic" |
| | | :permission="basicPermissionList" |
| | | :table-loading="loadingBasic" |
| | | class="code-basic-crud" |
| | | @row-click="codeBasicSecRowClick" |
| | | @search-change="basicSearchChange" |
| | | @search-reset="basicSearchReset" |
| | | @selection-change="selectionBasicChange" |
| | | @refresh-change="refreshChangeBasicSec" |
| | | > |
| | | <!-- 基础码段表格内操作按钮 --> |
| | | <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)" |
| | | >查看 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.editBtn && currentRuleLcStatus === 'Editing'" |
| | | 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')" |
| | | 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)" |
| | | >上移 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicDownBtn" |
| | | icon="el-icon-arrow-down" |
| | | plain |
| | | size="small" |
| | | type="text" |
| | | @click="downOrderNum(scope.row)" |
| | | >下移 |
| | | </el-button> |
| | | </template> |
| | | 码段管理 |
| | | </p> |
| | | <avue-crud |
| | | ref="crudBasic" |
| | | :data="basicData" |
| | | :option="optionBasic" |
| | | :permission="basicPermissionList" |
| | | :table-loading="loadingBasic" |
| | | class="code-basic-crud" |
| | | @row-click="codeBasicSecRowClick" |
| | | @search-change="basicSearchChange" |
| | | @search-reset="basicSearchReset" |
| | | @selection-change="selectionBasicChange" |
| | | @refresh-change="refreshChangeBasicSec" |
| | | > |
| | | <!-- 基础码段表格内操作按钮 --> |
| | | <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)" |
| | | >查看 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.editBtn && currentRuleLcStatus === 'Editing'" |
| | | 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')" |
| | | 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)" |
| | | >上移 |
| | | </el-button> |
| | | <el-button v-if="basicPermissionList.basicDownBtn" |
| | | 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" |
| | | > |
| | | 新 增 |
| | | </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)" |
| | | > |
| | | 删 除 |
| | | </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> |
| | | </template> |
| | | </avue-crud> |
| | | </div> |
| | | <!-- 基础码段表格左上方按钮区域 --> |
| | | <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" |
| | | > |
| | | 新 增 |
| | | </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)" |
| | | > |
| | | 删 除 |
| | | </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> |
| | | </template> |
| | | </avue-crud> |
| | | </div> |
| | | </basic-container> |
| | | |
| | | <!-- 码段码值管理对话框 --> |
| | |
| | | > |
| | | <!-- 第一层对话框,添加码段信息对话框中的内容 --> |
| | | <div class="add-basicsec-total"> |
| | | <el-form :model="form" class="add-basicsec-form" :rules="rules" > |
| | | <el-form :model="form" :rules="rules" class="add-basicsec-form"> |
| | | <span class="left"> |
| | | <el-form-item |
| | | :label-width="leftFormLabelWidth" |
| | |
| | | <template> |
| | | <vciWebRefer |
| | | ref="refer" |
| | | :referConfig="this.referConfig || {}" |
| | | :display="true" |
| | | :value="form.customCodeSerialClass" |
| | | :text="form.customCodeSerialClassText" |
| | | :referConfig="this.referConfig || {}" |
| | | :serialType="form.serialType" |
| | | :text="form.customCodeSerialClassText" |
| | | :value="form.customCodeSerialClass" |
| | | @setReferValue="setReferValue" |
| | | ></vciWebRefer> |
| | | </template> |
| | |
| | | <!-- 日期码段 --> |
| | | <div v-show="form.secType === 'codedatesec' ? true : false"> |
| | | <el-form-item |
| | | prop="Dateformat" |
| | | :label-width="rightFormLabelWidth" |
| | | label="日期格式:" |
| | | prop="Dateformat" |
| | | > |
| | | <el-input |
| | | ref="codeDateFormatStr" |
| | |
| | | import vciWebRefer from "../../components/refer/vciWebRefer"; |
| | | |
| | | export default { |
| | | components: { vciWebRefer }, |
| | | components: {vciWebRefer}, |
| | | data() { |
| | | return { |
| | | rules: { |
| | |
| | | required: true, |
| | | trigger: 'blur', |
| | | validator: (rule, value, callback) => { |
| | | const Formats = ['yy', 'yyyy', 'yyyy-MM', 'yy-MM', 'yyyy-MM-dd','yy-MM-dd', 'yyyy-MM-dd HH:mm:ss', 'yy-MM-dd HH:mm:ss', 'HH:mm:ss']; |
| | | const Formats = ['yy', 'yyyy', 'yyyy-MM', 'yy-MM', 'yyyy-MM-dd', 'yy-MM-dd', 'yyyy-MM-dd HH:mm:ss', 'yy-MM-dd HH:mm:ss', 'HH:mm:ss']; |
| | | if (!Formats.includes(this.form.codeDateFormatStr)) { |
| | | return callback(new Error('请输入正确日期格式,例如yyyy-MM-dd(并区分大小写)!')); |
| | | } |
| | |
| | | } |
| | | ] |
| | | }, |
| | | referConfig:{ |
| | | referConfig: { |
| | | title: '自定义流水参照', |
| | | showField: 'customCodeSerialClassText', |
| | | field: 'customCodeSerialClass', |
| | | fieldMap: { |
| | | serialType:"serialType" |
| | | fieldMap: { |
| | | serialType: "serialType" |
| | | }, |
| | | placeholder:'请选择自定义流水', |
| | | options: { |
| | | placeholder: '请选择自定义流水', |
| | | options: { |
| | | // 设置默认的属性 |
| | | url: 'api/ubcs-code/codeSerialAlgorithmController/gridCodeSerialAlgorithm', |
| | | textField:'name', |
| | | valueField:'classFullName', |
| | | textField: 'name', |
| | | valueField: 'classFullName', |
| | | isMuti: false, |
| | | type: "grid", |
| | | method: 'get', |
| | |
| | | }, |
| | | methods: { |
| | | //自定义流水失焦 |
| | | setReferValue(data){ |
| | | if(data.field){ |
| | | setReferValue(data) { |
| | | if (data.field) { |
| | | this.form[data.field] = data.value || ""; |
| | | this.form[data.showField] = data.text || ""; |
| | | this.form.serialType = data.rawData[0].serialType || ""; |
| | |
| | | } |
| | | //console.log(this.form); |
| | | //为form绑定值 |
| | | this.changeSectypeFormItems(condition == "add" ? null:row); |
| | | this.changeSectypeFormItems(condition == "add" ? null : row); |
| | | this.addBasicCodeSettingBox = true; |
| | | }, |
| | | /** 新增基础码段*/ |