Merge remote-tracking branch 'origin/material-ui' into material-ui
This commit is contained in:
commit
4f3eff18c7
|
|
@ -139,7 +139,7 @@
|
||||||
:options="uniteList" :normalizer="normalizer"
|
:options="uniteList" :normalizer="normalizer"
|
||||||
:show-count="true" style="width: 100%;" :disable-branch-nodes="true"
|
:show-count="true" style="width: 100%;" :disable-branch-nodes="true"
|
||||||
noChildrenText="没有数据了" noOptionsText="没有数据" noResultsText="没有搜索结果"
|
noChildrenText="没有数据了" noOptionsText="没有数据" noResultsText="没有搜索结果"
|
||||||
placeholder="请选择租赁单位"
|
placeholder="请选择租赁单位" @select="unitSelect"
|
||||||
/>
|
/>
|
||||||
<!-- <el-cascader
|
<!-- <el-cascader
|
||||||
v-model="unitId"
|
v-model="unitId"
|
||||||
|
|
@ -193,7 +193,7 @@
|
||||||
></el-cascader> -->
|
></el-cascader> -->
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
|
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="联系电话" prop="phone">
|
<el-form-item label="联系电话" prop="phone">
|
||||||
|
|
@ -219,6 +219,18 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="开始日期" prop="planStartTime">
|
||||||
|
<el-date-picker
|
||||||
|
style="width: 100%"
|
||||||
|
v-model="form.planStartTime"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
type="date"
|
||||||
|
placeholder="请选择开始日期"
|
||||||
|
:disabled="isEdits"
|
||||||
|
></el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
<!-- <el-col :span="12">
|
<!-- <el-col :span="12">
|
||||||
<el-form-item label="租赁期限(天)" prop="leaseDay">
|
<el-form-item label="租赁期限(天)" prop="leaseDay">
|
||||||
|
|
@ -233,22 +245,16 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>-->
|
</el-col>-->
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="开始日期" prop="planStartTime">
|
<el-form-item label="租赁单位类型">
|
||||||
<el-date-picker
|
<el-select style="width: 100%;" v-model="form.protocol" placeholder="请选择租赁单位类型" clearable :disabled="isEdits">
|
||||||
style="width: 100%"
|
<el-option label="内部单位" value="1"></el-option>
|
||||||
v-model="form.planStartTime"
|
<el-option label="外部单位" value="2"></el-option>
|
||||||
value-format="yyyy-MM-dd"
|
</el-select>
|
||||||
type="date"
|
|
||||||
placeholder="请选择开始日期"
|
|
||||||
:disabled="isEdits"
|
|
||||||
></el-date-picker>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="备注" prop="remark">
|
<el-form-item label="备注" prop="remark">
|
||||||
<el-input
|
<el-input
|
||||||
|
|
@ -260,19 +266,7 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="12">
|
|
||||||
<el-form-item label="租赁单位类型">
|
|
||||||
<el-select style="width: 100%;" v-model="form.protocol" placeholder="请选择租赁单位类型" clearable :disabled="isEdits">
|
|
||||||
<el-option label="内部单位" value="1"></el-option>
|
|
||||||
<el-option label="外部单位" value="2"></el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-form-item label="营业执照">
|
<el-form-item label="营业执照">
|
||||||
<el-upload
|
<el-upload
|
||||||
class="upload-demo"
|
class="upload-demo"
|
||||||
|
|
@ -484,33 +478,23 @@ export default {
|
||||||
return {
|
return {
|
||||||
uploadKey: Date.now(),
|
uploadKey: Date.now(),
|
||||||
// 遮罩层
|
// 遮罩层
|
||||||
loading: false,
|
loading: false,
|
||||||
|
loadingTwo: false,
|
||||||
loadingTwo: false,
|
|
||||||
|
|
||||||
|
|
||||||
// 是否显示项目部Id
|
// 是否显示项目部Id
|
||||||
showName: false,
|
showName: false,
|
||||||
|
|
||||||
// 是否显示施工预警信息
|
// 是否显示施工预警信息
|
||||||
showWarn: false,
|
showWarn: false,
|
||||||
|
|
||||||
|
|
||||||
// 非单个禁用
|
// 非单个禁用
|
||||||
single: true,
|
single: true,
|
||||||
// 非多个禁用
|
// 非多个禁用
|
||||||
multiple: true,
|
multiple: true,
|
||||||
|
|
||||||
// 日期范围
|
// 日期范围
|
||||||
dateRange: [],
|
dateRange: [],
|
||||||
|
|
||||||
// 显示搜索条件
|
// 显示搜索条件
|
||||||
showSearch: true,
|
showSearch: true,
|
||||||
showHouse: false,
|
showHouse: false,
|
||||||
showSee: false,
|
showSee: false,
|
||||||
showAllImg: false,
|
showAllImg: false,
|
||||||
|
|
||||||
|
|
||||||
// 总条数
|
// 总条数
|
||||||
total: 0,
|
total: 0,
|
||||||
totalTwo: 0,
|
totalTwo: 0,
|
||||||
|
|
@ -530,8 +514,7 @@ export default {
|
||||||
maForm: {
|
maForm: {
|
||||||
unitId: undefined,
|
unitId: undefined,
|
||||||
projectId: undefined
|
projectId: undefined
|
||||||
},
|
},
|
||||||
|
|
||||||
// 工程数据
|
// 工程数据
|
||||||
projectList: [],
|
projectList: [],
|
||||||
// 施工记录表格数据
|
// 施工记录表格数据
|
||||||
|
|
@ -566,7 +549,8 @@ export default {
|
||||||
form: {
|
form: {
|
||||||
unitId:null,
|
unitId:null,
|
||||||
projectId:null,
|
projectId:null,
|
||||||
},
|
protocol:'1'
|
||||||
|
},
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {
|
rules: {
|
||||||
unitId: [
|
unitId: [
|
||||||
|
|
@ -583,7 +567,13 @@ export default {
|
||||||
trigger: "blur",
|
trigger: "blur",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
contractCode: [
|
||||||
|
{
|
||||||
|
required: false,//是否分包商(是:合同编号必填)
|
||||||
|
message: '请填写合同编号',
|
||||||
|
trigger: 'change'
|
||||||
|
}
|
||||||
|
],
|
||||||
authPerson: [
|
authPerson: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
|
|
@ -807,7 +797,14 @@ export default {
|
||||||
this.projectList = response.data;
|
this.projectList = response.data;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
unitSelect(e){
|
||||||
|
console.log(e)
|
||||||
|
if(e.typeKey=='fbs'){
|
||||||
|
this.rules['contractCode'][0].required=true;
|
||||||
|
}else{
|
||||||
|
this.rules['contractCode'][0].required=false;
|
||||||
|
}
|
||||||
|
},
|
||||||
uniteChange(val) {
|
uniteChange(val) {
|
||||||
if (val && val.length > 0) {
|
if (val && val.length > 0) {
|
||||||
this.maForm.unitId = this.unitId[this.unitId.length - 1];
|
this.maForm.unitId = this.unitId[this.unitId.length - 1];
|
||||||
|
|
@ -964,7 +961,16 @@ export default {
|
||||||
|
|
||||||
// 表单重置
|
// 表单重置
|
||||||
reset() {
|
reset() {
|
||||||
this.form = {};
|
this.form = {
|
||||||
|
unitId:null,
|
||||||
|
projectId:null,
|
||||||
|
authPerson:"",
|
||||||
|
phone:'',
|
||||||
|
contractCode:'',
|
||||||
|
planStartTime:'',
|
||||||
|
protocol:"1",
|
||||||
|
remark:'',
|
||||||
|
};
|
||||||
this.unitId = null;
|
this.unitId = null;
|
||||||
this.projectId = null;
|
this.projectId = null;
|
||||||
this.maForm = {
|
this.maForm = {
|
||||||
|
|
@ -1006,15 +1012,14 @@ export default {
|
||||||
await this.editAgreementTemp(this.form);
|
await this.editAgreementTemp(this.form);
|
||||||
await this.deleteFile();
|
await this.deleteFile();
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
console.log(1)
|
console.log(1)
|
||||||
if (this.businessLicenseListTemp.length != 0) {
|
if (this.businessLicenseListTemp.length != 0) {
|
||||||
console.log(2)
|
// console.log(2)
|
||||||
await this.getImaUpload(),
|
await this.getImaUpload(),
|
||||||
await this.addAgreementTemp(this.form);
|
await this.addAgreementTemp(this.form);
|
||||||
} else {
|
} else {
|
||||||
console.log(3)
|
// console.log(3)
|
||||||
await this.addAgreementTemp(this.form);
|
await this.addAgreementTemp(this.form);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -176,13 +176,7 @@
|
||||||
v-model.number="scope.row.purchaseNum"
|
v-model.number="scope.row.purchaseNum"
|
||||||
controls-position="right" type="number"
|
controls-position="right" type="number"
|
||||||
style="width: 100%" :disabled="scope.row.status!=1&&scope.row.status!=12"
|
style="width: 100%" :disabled="scope.row.status!=1&&scope.row.status!=12"
|
||||||
:min="0"
|
:min="0" @input="v =>scope.row.unitValue == 1? (scope.row.purchaseNum = Number(v.replace(/[^\d.]/g, ''))): (scope.row.purchaseNum = Number(v.replace(/[^\d]/g, '')))"
|
||||||
@input="
|
|
||||||
v =>
|
|
||||||
scope.row.unitValue == 1
|
|
||||||
? (scope.row.purchaseNum = Number(v.replace(/[^\d.]/g, '')))
|
|
||||||
: (scope.row.purchaseNum = Number(v.replace(/[^\d]/g, '')))
|
|
||||||
"
|
|
||||||
></el-input>
|
></el-input>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
@ -623,8 +617,7 @@ export default {
|
||||||
},
|
},
|
||||||
// 处理类型数据
|
// 处理类型数据
|
||||||
processTypeData(data) {
|
processTypeData(data) {
|
||||||
const result = []
|
const result = []
|
||||||
|
|
||||||
const traverse = (node, parents = []) => {
|
const traverse = (node, parents = []) => {
|
||||||
const path = [...parents, node.typeName]
|
const path = [...parents, node.typeName]
|
||||||
|
|
||||||
|
|
@ -638,7 +631,8 @@ export default {
|
||||||
maTypeName: parents[parents.length - 1] || '',
|
maTypeName: parents[parents.length - 1] || '',
|
||||||
specificationType: node.typeName,
|
specificationType: node.typeName,
|
||||||
unitName: node.unitName,
|
unitName: node.unitName,
|
||||||
unitValue: node.unitValue
|
unitValue: node.unitValue,
|
||||||
|
rentPrice: node.rentPrice,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -664,8 +658,7 @@ export default {
|
||||||
},
|
},
|
||||||
// 选择变化处理
|
// 选择变化处理
|
||||||
handleTypeChange(val) {
|
handleTypeChange(val) {
|
||||||
if (!val || val.length === 0) return
|
if (!val || val.length === 0) return
|
||||||
|
|
||||||
// 获取新选中的项
|
// 获取新选中的项
|
||||||
const lastSelected = val[val.length - 1]
|
const lastSelected = val[val.length - 1]
|
||||||
const typeData = this.flattenTypeOptions.find(item => item.typeId === lastSelected)
|
const typeData = this.flattenTypeOptions.find(item => item.typeId === lastSelected)
|
||||||
|
|
@ -681,10 +674,25 @@ export default {
|
||||||
this.$message.error('所选物资规格类型暂时无库存,无法申请!')
|
this.$message.error('所选物资规格类型暂时无库存,无法申请!')
|
||||||
this.tempDeviceType = this.tempDeviceType.filter(id => id !== lastSelected)
|
this.tempDeviceType = this.tempDeviceType.filter(id => id !== lastSelected)
|
||||||
} else {
|
} else {
|
||||||
|
console.log(typeData,"typeData")
|
||||||
|
if(typeData.rentPrice>0){//判断是否有租赁价格:有禁用;无修改;
|
||||||
|
typeData.rentPriceDisabled=true
|
||||||
|
}else{
|
||||||
|
typeData.rentPriceDisabled=false
|
||||||
|
}
|
||||||
// 将新项添加到数组开头,实现倒序
|
// 将新项添加到数组开头,实现倒序
|
||||||
this.equipmentList.unshift({
|
this.equipmentList.unshift({
|
||||||
...typeData,
|
...typeData,
|
||||||
preNum: 0
|
preNum: 0,
|
||||||
|
createTime: null,
|
||||||
|
productionTime: this.maForm.productionTime,
|
||||||
|
purchaseTaxPrice: 0,
|
||||||
|
purchaseTaxPrice: 0,
|
||||||
|
purchaseNum : 1,
|
||||||
|
fixCode: '0',
|
||||||
|
status:1,
|
||||||
|
bmFileInfos:[]
|
||||||
|
|
||||||
})
|
})
|
||||||
this.deviceType.push(lastSelected)
|
this.deviceType.push(lastSelected)
|
||||||
this.$message({
|
this.$message({
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue