| | |
| | | :customStyle="textareaStyle(!form.diagnosisname)" |
| | | /> |
| | | </view> |
| | | |
| | | <view class="form-item"> |
| | | <text class="item-label">是否需要转运</text> |
| | | <view class="radio-group horizontal"> |
| | | <view |
| | | v-for="bloodType in isTransportOptions" |
| | | :key="bloodType.value" |
| | | class="radio-item" |
| | | @click="form.isTransport = bloodType.value" |
| | | > |
| | | <view |
| | | class="radio-dot" |
| | | :class="{ active: form.isTransport === bloodType.value }" |
| | | ></view> |
| | | <text class="radio-label">{{ bloodType.label }}</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="form-item"> |
| | | <text class="item-label">血型</text> |
| | | <view class="radio-group horizontal"> |
| | |
| | | { label: "O型", value: "O" }, |
| | | { label: "AB型", value: "AB" }, |
| | | ]); |
| | | |
| | | const isTransportOptions = ref([ |
| | | { label: "需要", value: "2" }, |
| | | { label: "不需要", value: "1" }, |
| | | ]); |
| | | const rhOptions = ref([ |
| | | { label: "阳性", value: "positive" }, |
| | | { label: "阴性", value: "negative" }, |
| | |
| | | ? idCardTypeLabels.value[idCardTypeIndex.value] |
| | | : "请选择证件类型"; |
| | | }); |
| | | |
| | | |
| | | const onNationChange = (e) => { |
| | | const index = parseInt(e.detail.value); |
| | |
| | | |
| | | // 处理其他附件上传 |
| | | const handleFilesUpdate = (files) => { |
| | | formData.attachments = files.map((file) => ({ |
| | | attachments.value = files.map((file) => ({ |
| | | ...file, |
| | | // 确保只存储半路径 |
| | | url: file.url.startsWith("http") |
| | |
| | | |
| | | if (file.type.includes("image")) { |
| | | uni.previewImage({ |
| | | urls: formData.attachments |
| | | urls: attachments.value |
| | | .filter((f) => f.type.includes("image")) |
| | | .map((f) => |
| | | f.url.startsWith("http") |
| | |
| | | } |
| | | |
| | | try { |
| | | uni.showLoading({ title: isEditMode.value ? "修改中..." : "提交中..." }); |
| | | console.log(attachments.value); |
| | | |
| | | uni.showLoading({ title: isEditMode.value ? "修改中..." : "提交中..." }); |
| | | // 准备提交数据 |
| | | const submitData = { |
| | | ...form.value, |