Browse Source

修复部分bug

master
qb 8 months ago
parent
commit
93d0597d08
  1. 4
      config/host.js
  2. 29
      pagesHome/pages/afterSalesDetails/afterSalesDetails.vue
  3. 11
      pagesHome/pages/taskDetails/clientInfo.vue
  4. 4
      pagesUser/pages/InstallTaskList/InstallTaskList.vue

4
config/host.js

@ -23,8 +23,8 @@
// cg
// const devhost = 'http://192.168.10.200:13000/'
// lg
// const devhost = 'http://192.168.3.16:9922/'
const devhost = 'http://192.168.5.34:9922/'
const devhost = 'http://192.168.3.16:9922/'
// const devhost = 'http://192.168.5.34:9922/'
/**
* 正式域名
* */

29
pagesHome/pages/afterSalesDetails/afterSalesDetails.vue

@ -12,7 +12,7 @@
</view>
<view class="mt20">
关联任务编号
关联任务编号{{details.info.install && details.info.install.no}}
</view>
</view>
@ -87,7 +87,8 @@
确认完工
</view>
<view class="button primaryColor" @click="handleConfirmCompletion">
<view class="button primaryColor" @click="handleConfirmCompletion"
v-if="details.buttonPermissionObj.confirmAOG">
确认到货
</view>
@ -347,6 +348,28 @@
return false
}),
/** 确认到货 */
confirmAOG: computed(() => {
const { id } = details.userInfo
console.log('id :>> ', id);
const { installSales, installWork } = details.info as any
if (utils.getObjType(installSales) !== 'object' || utils.getObjType(installWork) !== 'object') return false
if (!installWork.work_user_ids || !installWork.work_user_ids.includes(id)) return false
if (installSales.type === 5 || installSales.type === 6) return true
const _status = Number(installSales.status)
const whiteArr = [4]
if (whiteArr.includes(_status)) return true
return false
}),
/** 确认指派 */
confirmAssign: computed(() => {
console.log('Number(details.userInfo.role_code) :>> ', Number(details.userInfo.role_code));
@ -373,8 +396,6 @@
onLoad(async (e) => {
console.log('e :>> ', e);
details.pageInfo = JSON.parse(e.pageInfo)
})
onShow(async () => {

11
pagesHome/pages/taskDetails/clientInfo.vue

@ -73,8 +73,8 @@
</view> -->
<view class="row flex-c-sb">
<text class="title">完成时间</text>
<text class="info">{{info.install_time}}</text>
<text class="title">完成时间</text>
<text class="info">{{installWork.estimated_finish_time}}</text>
</view>
<view class="row flex-c-sb">
@ -141,6 +141,13 @@
else return {}
})
const installWork = computed(() => {
console.log('props.info :>> ', props.info);
if (props.info && props.info.installWork) return props.info.installWork
else return {}
})
/** 打电话 */
const handleCallPhone = () => {
uni.makePhoneCall({

4
pagesUser/pages/InstallTaskList/InstallTaskList.vue

@ -114,7 +114,7 @@
</view>
<view class="mt20 flex-c-sb">
<text>预计完成时间{{ item.expect_install_time }}</text>
<text>预计安装时间{{ item.expect_install_time }}</text>
</view>
</view>
</view>
@ -150,7 +150,7 @@
<view>安装人员{{ item.work_users }}</view>
</view>
<view class="mt10">预计完成时间{{ item.expect_install_time }}</view>
<view class="mt10">预计安装时间{{ item.expect_install_time }}</view>
</view>
</view>
</template>

Loading…
Cancel
Save