|
|
|
@ -132,16 +132,17 @@ export class FileCategoryComponent implements OnInit {
|
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
instance.data2.validatyType = Number(instance.validatyType) |
|
|
|
|
if (instance.data2.imageUrl.indexOf('http') == -1) { |
|
|
|
|
if (instance.data2.imageUrl && instance.data2.imageUrl.indexOf('http') == -1) { |
|
|
|
|
let newUrl = window.location.protocol + '//' + window.location.host + instance.data2.imageUrl |
|
|
|
|
instance.data2.imageUrl = newUrl |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (!instance.isSubmit) { |
|
|
|
|
this.http.post('/api/services/app/StationFileLicense/Create', instance.data2).subscribe((data: any) => { |
|
|
|
|
this.getStationList(); |
|
|
|
|
this.message.create('success', '修改成功!'); |
|
|
|
|
}) |
|
|
|
|
return false; |
|
|
|
|
return true; |
|
|
|
|
} else { |
|
|
|
|
await new Promise(resolve => { |
|
|
|
|
this.http.post('/api/services/app/StationFileLicense/Create', instance.data2).subscribe((data: any) => { |
|
|
|
|