Loading src/views/riskProject/add/riskAppvoreText.vue +12 −23 Original line number Original line Diff line number Diff line <template> <template> <div> <div> <LHeader text="备注"></LHeader> <LHeader text="备注"></LHeader> <van-field <van-field v-model="messageText" rows="10" autosize label="备注信息" type="textarea" maxlength="500" v-model="messageText" placeholder="请输入备注信息" show-word-limit /> rows="10" <div style="display: flex; autosize label="备注信息" type="textarea" maxlength="500" placeholder="请输入备注信息" show-word-limit /> <div style="display: flex; justify-content: space-around; justify-content: space-around; background-color: #fff; background-color: #fff; border-top: 1px solid #e3e3e3; border-top: 1px solid #e3e3e3; Loading @@ -20,12 +11,8 @@ width: 100%; width: 100%; text-align: center; text-align: center; position: fixed; position: fixed; bottom: 0;" bottom: 0;"> > <div @click="appvore" style="color: #4bced0;font-size: 14px;font-weight: 600;"> <div @click="appvore" style="color: #4bced0;font-size: 14px;font-weight: 600;" > <div style="font-size: 22px;"><van-icon name="success" /></div> <div style="font-size: 22px;"><van-icon name="success" /></div> <div>保存</div> <div>保存</div> </div> </div> Loading Loading @@ -74,15 +61,17 @@ export default { buildingDtos: buildingDtos buildingDtos: buildingDtos }; }; postFun("/risk/plan/approve", params) postFun("/risk/plan/approve", params) .then(res => {}) .then(res => { .catch(() => { this.$toast.clear(); this.$toast.fail("加载失败,请稍后再试"); }); this.$router.replace({ this.$router.replace({ name: "riskApprove", name: "riskApprove", params: {} params: {} }); }); }) .catch(() => { this.$toast.clear(); this.$toast.fail("加载失败,请稍后再试"); }); } } }, }, watch: {} watch: {} Loading src/views/riskProject/add/taskList.vue +48 −4 Original line number Original line Diff line number Diff line Loading @@ -192,23 +192,23 @@ </div> </div> </van-tab> </van-tab> <van-tab title="评估报告"> <van-tab title="评估报告"> <a style="height: 1.5rem; <div style="height: 1.5rem; background-color: #fff; background-color: #fff; border-bottom: 1px solid #97999a; border-bottom: 1px solid #97999a; display: flex; display: flex; justify-content: space-between; justify-content: space-between; line-height: 1.5rem; line-height: 1.5rem; color:#010101; color:#010101; " :href="fileUrl()" target="_blank"> " @click="adviceOpen"> <div><van-icon name="column" size="26px" /></div> <div><van-icon name="column" size="26px" /></div> <div style="flex-grow:1;line-height: 0.6rem"> <div style="flex-grow:1;line-height: 0.6rem"> <div>风险评估报告模板.docx</div> <div>风险评估报告模板.docx</div> <div>2019-3-21 10:23 154KB</div> <div>2019-3-21 10:23</div> </div> </div> <div> <div> <van-icon name="arrow" size="26px" /> <van-icon name="arrow" size="26px" /> </div> </div> </a> </div> </van-tab> </van-tab> </van-tabs> </van-tabs> </div> </div> Loading Loading @@ -373,6 +373,11 @@ </div> </div> </van-cell-group> </van-cell-group> </van-popup> </van-popup> <van-dialog v-model="advice.visible" title="标题" show-cancel-button :before-close="isCloseAdvice" @cancel="cancelAdvice"> <van-field class="advice-field" required v-model="advice.value" type="textarea" label="风险管控建议" placeholder="请输入风险管控建议" /> </van-dialog> </div> </div> </template> </template> Loading @@ -387,6 +392,12 @@ export default { }, }, data() { data() { return { return { advice: { visible: false, value: '', open: this.adviceOpen, close: this.adviceClose }, text: "任务单", text: "任务单", searchValue: "", searchValue: "", messageText: "", messageText: "", Loading Loading @@ -435,6 +446,32 @@ export default { this.getBuildingFList() this.getBuildingFList() }, }, methods: { methods: { adviceOpen() { this.advice.visible = true; }, adviceClose() { this.advice.visible = false; }, isCloseAdvice(action, done) { if (action === 'confirm') { if (this.advice.value.trim() == "") { this.$toast.fail("请输入风险管控建议"); done(false); return; } else { postFun(`/risk/advise`, { value: this.advice.value, id: this.planId }).then(res => { done(); window.open(res.data); }) } } else { this.advice.value = ""; done(); } }, timestampToTimes(time, type) { timestampToTimes(time, type) { return timestampToTime(new Date(time), type, true); return timestampToTime(new Date(time), type, true); }, }, Loading Loading @@ -781,4 +818,11 @@ p { text-overflow: ellipsis; text-overflow: ellipsis; overflow: hidden; overflow: hidden; } } .advice-field { ::v-deep .van-field__body { background: #f5f5f5; padding: 3px 10px; } } </style> </style> src/views/riskProject/approve/index.vue +16 −35 Original line number Original line Diff line number Diff line Loading @@ -4,21 +4,11 @@ <van-sticky offset-top="0"> <van-sticky offset-top="0"> <LHeader :text="text"></LHeader> <LHeader :text="text"></LHeader> </van-sticky> </van-sticky> <van-tabs <van-tabs v-model="active" @change="postList" color="#2980f7" animated :sticky="true"> v-model="active" @change="postList" color="#2980f7" animated :sticky="true" > <van-tab v-for="item in tabs" :key="item.key" :title="item.title"> <van-tab v-for="item in tabs" :key="item.key" :title="item.title"> <!-- 内容列表 --> <!-- 内容列表 --> <div class="con-list"> <div class="con-list"> <van-cell-group <van-cell-group inset v-for="(item, index) in messageList" :key="index"> inset v-for="(item, index) in messageList" :key="index" > <div style="font-size: 0.45rem;padding: 5px 0;"> <div style="font-size: 0.45rem;padding: 5px 0;"> {{ item.name }} {{ item.name }} </div> </div> Loading @@ -36,39 +26,30 @@ </van-row> </van-row> </van-col> </van-col> <van-col span="7"> <van-col span="7"> <van-row <van-row :style="{ :style="{ color: color: active == 0 active == 0 ? '#f79648' ? '#f79648' : active == 1 : active == 1 ? '#0069e5' ? '#0069e5' : '#03b615' : '#03b615' }" }"> > {{ item.state }} {{ item.state }} </van-row> </van-row> <van-row> <van-row> <van-button <van-button type="info" size="mini" @click="todetail(index, item)">{{ active == 0 ? "去审批" : "查看详情" type="info" }}</van-button> size="mini" @click="todetail(index, item)" >{{ active == 0 ? "去审批" : "查看详情" }}</van-button > </van-row> </van-row> </van-col> </van-col> </van-row> </van-row> </van-cell-group> </van-cell-group> <div <div style=" style=" width: 100%; width: 100%; text-align: center; text-align: center; font-size: 0.48rem; font-size: 0.48rem; position: fixed; position: fixed; top: 30%; top: 30%; " " v-if="messageList['length'] == 0"> v-if="messageList['length'] == 0" > 暂无数据 暂无数据 </div> </div> </div> </div> Loading vue.config.js +2 −2 Original line number Original line Diff line number Diff line Loading @@ -10,8 +10,8 @@ module.exports = { proxy: { proxy: { //配置跨域 //配置跨域 "/app-api": { "/app-api": { target: "http://192.168.4.232:8080/", //这里是后台的地址 // target: "http://192.168.4.232:8080/", //这里是后台的地址 // target: "http://192.168.15.230:8080/", //这里是晓晋的地址 target: "http://192.168.15.230:8080/", //这里是晓晋的地址 ws: true, ws: true, changOrigin: true, //允许跨域 changOrigin: true, //允许跨域 // logLevel: 'debug', // 显示代理调试信息 // logLevel: 'debug', // 显示代理调试信息 Loading Loading
src/views/riskProject/add/riskAppvoreText.vue +12 −23 Original line number Original line Diff line number Diff line <template> <template> <div> <div> <LHeader text="备注"></LHeader> <LHeader text="备注"></LHeader> <van-field <van-field v-model="messageText" rows="10" autosize label="备注信息" type="textarea" maxlength="500" v-model="messageText" placeholder="请输入备注信息" show-word-limit /> rows="10" <div style="display: flex; autosize label="备注信息" type="textarea" maxlength="500" placeholder="请输入备注信息" show-word-limit /> <div style="display: flex; justify-content: space-around; justify-content: space-around; background-color: #fff; background-color: #fff; border-top: 1px solid #e3e3e3; border-top: 1px solid #e3e3e3; Loading @@ -20,12 +11,8 @@ width: 100%; width: 100%; text-align: center; text-align: center; position: fixed; position: fixed; bottom: 0;" bottom: 0;"> > <div @click="appvore" style="color: #4bced0;font-size: 14px;font-weight: 600;"> <div @click="appvore" style="color: #4bced0;font-size: 14px;font-weight: 600;" > <div style="font-size: 22px;"><van-icon name="success" /></div> <div style="font-size: 22px;"><van-icon name="success" /></div> <div>保存</div> <div>保存</div> </div> </div> Loading Loading @@ -74,15 +61,17 @@ export default { buildingDtos: buildingDtos buildingDtos: buildingDtos }; }; postFun("/risk/plan/approve", params) postFun("/risk/plan/approve", params) .then(res => {}) .then(res => { .catch(() => { this.$toast.clear(); this.$toast.fail("加载失败,请稍后再试"); }); this.$router.replace({ this.$router.replace({ name: "riskApprove", name: "riskApprove", params: {} params: {} }); }); }) .catch(() => { this.$toast.clear(); this.$toast.fail("加载失败,请稍后再试"); }); } } }, }, watch: {} watch: {} Loading
src/views/riskProject/add/taskList.vue +48 −4 Original line number Original line Diff line number Diff line Loading @@ -192,23 +192,23 @@ </div> </div> </van-tab> </van-tab> <van-tab title="评估报告"> <van-tab title="评估报告"> <a style="height: 1.5rem; <div style="height: 1.5rem; background-color: #fff; background-color: #fff; border-bottom: 1px solid #97999a; border-bottom: 1px solid #97999a; display: flex; display: flex; justify-content: space-between; justify-content: space-between; line-height: 1.5rem; line-height: 1.5rem; color:#010101; color:#010101; " :href="fileUrl()" target="_blank"> " @click="adviceOpen"> <div><van-icon name="column" size="26px" /></div> <div><van-icon name="column" size="26px" /></div> <div style="flex-grow:1;line-height: 0.6rem"> <div style="flex-grow:1;line-height: 0.6rem"> <div>风险评估报告模板.docx</div> <div>风险评估报告模板.docx</div> <div>2019-3-21 10:23 154KB</div> <div>2019-3-21 10:23</div> </div> </div> <div> <div> <van-icon name="arrow" size="26px" /> <van-icon name="arrow" size="26px" /> </div> </div> </a> </div> </van-tab> </van-tab> </van-tabs> </van-tabs> </div> </div> Loading Loading @@ -373,6 +373,11 @@ </div> </div> </van-cell-group> </van-cell-group> </van-popup> </van-popup> <van-dialog v-model="advice.visible" title="标题" show-cancel-button :before-close="isCloseAdvice" @cancel="cancelAdvice"> <van-field class="advice-field" required v-model="advice.value" type="textarea" label="风险管控建议" placeholder="请输入风险管控建议" /> </van-dialog> </div> </div> </template> </template> Loading @@ -387,6 +392,12 @@ export default { }, }, data() { data() { return { return { advice: { visible: false, value: '', open: this.adviceOpen, close: this.adviceClose }, text: "任务单", text: "任务单", searchValue: "", searchValue: "", messageText: "", messageText: "", Loading Loading @@ -435,6 +446,32 @@ export default { this.getBuildingFList() this.getBuildingFList() }, }, methods: { methods: { adviceOpen() { this.advice.visible = true; }, adviceClose() { this.advice.visible = false; }, isCloseAdvice(action, done) { if (action === 'confirm') { if (this.advice.value.trim() == "") { this.$toast.fail("请输入风险管控建议"); done(false); return; } else { postFun(`/risk/advise`, { value: this.advice.value, id: this.planId }).then(res => { done(); window.open(res.data); }) } } else { this.advice.value = ""; done(); } }, timestampToTimes(time, type) { timestampToTimes(time, type) { return timestampToTime(new Date(time), type, true); return timestampToTime(new Date(time), type, true); }, }, Loading Loading @@ -781,4 +818,11 @@ p { text-overflow: ellipsis; text-overflow: ellipsis; overflow: hidden; overflow: hidden; } } .advice-field { ::v-deep .van-field__body { background: #f5f5f5; padding: 3px 10px; } } </style> </style>
src/views/riskProject/approve/index.vue +16 −35 Original line number Original line Diff line number Diff line Loading @@ -4,21 +4,11 @@ <van-sticky offset-top="0"> <van-sticky offset-top="0"> <LHeader :text="text"></LHeader> <LHeader :text="text"></LHeader> </van-sticky> </van-sticky> <van-tabs <van-tabs v-model="active" @change="postList" color="#2980f7" animated :sticky="true"> v-model="active" @change="postList" color="#2980f7" animated :sticky="true" > <van-tab v-for="item in tabs" :key="item.key" :title="item.title"> <van-tab v-for="item in tabs" :key="item.key" :title="item.title"> <!-- 内容列表 --> <!-- 内容列表 --> <div class="con-list"> <div class="con-list"> <van-cell-group <van-cell-group inset v-for="(item, index) in messageList" :key="index"> inset v-for="(item, index) in messageList" :key="index" > <div style="font-size: 0.45rem;padding: 5px 0;"> <div style="font-size: 0.45rem;padding: 5px 0;"> {{ item.name }} {{ item.name }} </div> </div> Loading @@ -36,39 +26,30 @@ </van-row> </van-row> </van-col> </van-col> <van-col span="7"> <van-col span="7"> <van-row <van-row :style="{ :style="{ color: color: active == 0 active == 0 ? '#f79648' ? '#f79648' : active == 1 : active == 1 ? '#0069e5' ? '#0069e5' : '#03b615' : '#03b615' }" }"> > {{ item.state }} {{ item.state }} </van-row> </van-row> <van-row> <van-row> <van-button <van-button type="info" size="mini" @click="todetail(index, item)">{{ active == 0 ? "去审批" : "查看详情" type="info" }}</van-button> size="mini" @click="todetail(index, item)" >{{ active == 0 ? "去审批" : "查看详情" }}</van-button > </van-row> </van-row> </van-col> </van-col> </van-row> </van-row> </van-cell-group> </van-cell-group> <div <div style=" style=" width: 100%; width: 100%; text-align: center; text-align: center; font-size: 0.48rem; font-size: 0.48rem; position: fixed; position: fixed; top: 30%; top: 30%; " " v-if="messageList['length'] == 0"> v-if="messageList['length'] == 0" > 暂无数据 暂无数据 </div> </div> </div> </div> Loading
vue.config.js +2 −2 Original line number Original line Diff line number Diff line Loading @@ -10,8 +10,8 @@ module.exports = { proxy: { proxy: { //配置跨域 //配置跨域 "/app-api": { "/app-api": { target: "http://192.168.4.232:8080/", //这里是后台的地址 // target: "http://192.168.4.232:8080/", //这里是后台的地址 // target: "http://192.168.15.230:8080/", //这里是晓晋的地址 target: "http://192.168.15.230:8080/", //这里是晓晋的地址 ws: true, ws: true, changOrigin: true, //允许跨域 changOrigin: true, //允许跨域 // logLevel: 'debug', // 显示代理调试信息 // logLevel: 'debug', // 显示代理调试信息 Loading